Skip to content

Commit

Permalink
Apply prettier to root js files
Browse files Browse the repository at this point in the history
  • Loading branch information
rosszurowski committed Oct 8, 2017
1 parent 1fa45d4 commit 81b16ac
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 62 deletions.
97 changes: 50 additions & 47 deletions css.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,53 +8,56 @@ const breakpoints = {
m: '959px',
};

const fcss = hibiscss(kit({
colors: {
pink: '#ffb7b3',
black: '#141414',
green: '#00bf83',
lightGray: '#f2f2f2',
},
fontFamily: {
sans: '-apple-system, BlinkMacSystemFont, Arial, sans-serif',
mono: 'SFMono-Regular, menlo, monaco, monospace',
},
fontSize: {
13: '13px',
15: '15px',
18: '18px',
22: '22px',
27: '27px',
33: '33px',
64: '64px',
},
fontWeight: {
light: 300,
normal: 400,
bold: 500,
},
lineHeight: {
'1.7': 1.7,
},
letterSpacing: {
1: '1px',
},
sizes: {
'1': '1rem',
'2': '2rem',
'3': '3rem',
'4': '4rem',
'5': '5rem',
'100%': '100%',
},
maxWidths: {
540: '540px',
900: '900px',
1200: '1200px',
'100%': '100%'
},
spacing: [0, 4, 8, 16, 32, 64, 128],
}), breakpoints);
const fcss = hibiscss(
kit({
colors: {
pink: '#ffb7b3',
black: '#141414',
green: '#00bf83',
lightGray: '#f2f2f2',
},
fontFamily: {
sans: '-apple-system, BlinkMacSystemFont, Arial, sans-serif',
mono: 'SFMono-Regular, menlo, monaco, monospace',
},
fontSize: {
13: '13px',
15: '15px',
18: '18px',
22: '22px',
27: '27px',
33: '33px',
64: '64px',
},
fontWeight: {
light: 300,
normal: 400,
bold: 500,
},
lineHeight: {
'1.7': 1.7,
},
letterSpacing: {
1: '1px',
},
sizes: {
'1': '1rem',
'2': '2rem',
'3': '3rem',
'4': '4rem',
'5': '5rem',
'100%': '100%',
},
maxWidths: {
540: '540px',
900: '900px',
1200: '1200px',
'100%': '100%',
},
spacing: [0, 4, 8, 16, 32, 64, 128],
}),
breakpoints,
);

const global = `
html {
Expand Down
20 changes: 5 additions & 15 deletions next.config.js
Original file line number Diff line number Diff line change
@@ -1,26 +1,16 @@
const fs = require('mz/fs');

const stripExtension = str => str.replace(/\.js$/, '');
const pathsToPages = paths => paths.reduce(
(pages, path) => ({ ...pages, [path]: { page: path } }),
{}
);
const pathsToPages = paths => paths.reduce((pages, path) => ({ ...pages, [path]: { page: path } }), {});

const getLogPaths = async () => {
const entries = await fs.readdir('./pages/log');
return entries
.map(stripExtension)
.map(path => `/log/${path}`);
}
return entries.map(stripExtension).map(path => `/log/${path}`);
};

module.exports = {
async exportPathMap () {
const staticPaths = [
'/',
'/2017/japan',
'/100',
'/_error',
];
async exportPathMap() {
const staticPaths = ['/', '/2017/japan', '/100', '/_error'];

const logPaths = await getLogPaths();

Expand Down

0 comments on commit 81b16ac

Please sign in to comment.