mirror of
https://github.com/facebook/docusaurus.git
synced 2025-08-04 01:09:20 +02:00
feat(v2): add Prettier to Facebook template (#2156)
This commit is contained in:
parent
08ca95af01
commit
bf1ae60031
3 changed files with 17 additions and 3 deletions
|
@ -0,0 +1,3 @@
|
|||
node_modules
|
||||
build
|
||||
.docusaurus
|
8
packages/docusaurus-init/templates/facebook/.prettierrc
Normal file
8
packages/docusaurus-init/templates/facebook/.prettierrc
Normal file
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
"bracketSpacing": false,
|
||||
"jsxBracketSameLine": true,
|
||||
"printWidth": 80,
|
||||
"proseWrap": "never",
|
||||
"singleQuote": true,
|
||||
"trailingComma": "all"
|
||||
}
|
|
@ -7,8 +7,10 @@
|
|||
"build": "docusaurus build",
|
||||
"swizzle": "docusaurus swizzle",
|
||||
"deploy": "docusaurus deploy",
|
||||
"ci": "yarn lint",
|
||||
"lint": "eslint --cache \"**/*.js\""
|
||||
"ci": "yarn lint && yarn prettier:diff",
|
||||
"lint": "eslint --cache \"**/*.js\"",
|
||||
"prettier": "prettier --config .prettierrc --write \"**/*.{js,md}\"",
|
||||
"prettier:diff": "prettier --config .prettierrc --list-different \"**/*.{js,md}\""
|
||||
},
|
||||
"dependencies": {
|
||||
"@docusaurus/core": "^2.0.0-alpha.40",
|
||||
|
@ -26,7 +28,8 @@
|
|||
"eslint-plugin-import": "^2.18.2",
|
||||
"eslint-plugin-jsx-a11y": "^6.2.3",
|
||||
"eslint-plugin-react": "^7.16.0",
|
||||
"eslint-plugin-react-hooks": "^2.3.0"
|
||||
"eslint-plugin-react-hooks": "^2.3.0",
|
||||
"prettier": "^1.19.1"
|
||||
},
|
||||
"browserslist": {
|
||||
"production": [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue