Skip to content

Commit 7cdf63e

Browse files
committed
chore: add prettier
1 parent 0ee28e2 commit 7cdf63e

File tree

4 files changed

+24
-0
lines changed

4 files changed

+24
-0
lines changed

.prettierignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
.next
2+
.now
3+
dist
4+
public
5+
*.json
6+
*.d.ts
7+
*.yml

.prettierrc.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
module.exports = {
2+
semi: false,
3+
tabWidth: 2,
4+
printWidth: 100,
5+
trailingComma: 'all',
6+
arrowParens: 'avoid',
7+
singleQuote: true,
8+
jsxBracketSameLine: true,
9+
endOfLine: 'lf',
10+
}

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
"dev": "npm run collect && next dev",
88
"now-build": "npm run collect && next build",
99
"post": "node scripts/create.js",
10+
"prettier": "prettier --write .",
1011
"collect": "node scripts/collect-meta.js",
1112
"export": "npm run now-build && next export"
1213
},
@@ -28,6 +29,7 @@
2829
"chalk": "^3.0.0",
2930
"extract-mdx-metadata": "^1.0.0",
3031
"fs-extra": "^8.1.0",
32+
"prettier": "^2.0.5",
3133
"prompt-sync": "^4.2.0",
3234
"rehype-join-line": "^1.0.2",
3335
"styled-jsx": "^3.2.4"

yarn.lock

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4992,6 +4992,11 @@ prepend-http@^1.0.0:
49924992
resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc"
49934993
integrity sha1-1PRWKwzjaW5BrFLQ4ALlemNdxtw=
49944994

4995+
prettier@^2.0.5:
4996+
version "2.0.5"
4997+
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.0.5.tgz#d6d56282455243f2f92cc1716692c08aa31522d4"
4998+
integrity sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==
4999+
49955000
prismjs@~1.17.0:
49965001
version "1.17.1"
49975002
resolved "https://registry.yarnpkg.com/prismjs/-/prismjs-1.17.1.tgz#e669fcbd4cdd873c35102881c33b14d0d68519be"

0 commit comments

Comments
 (0)