mirror of
https://git.netzspielplatz.de/docker-multiarch/openwrt-firmware-selector.git
synced 2025-11-08 22:29:28 +00:00
Add prettier support
Add prettier and bind it with eslint. Also add pre-commit hook to prettify before commit Signed-off-by: Sudhanshu Gautam <me@sudhanshug.com>
This commit is contained in:
parent
3f46d13ccf
commit
ce4d2e1436
13 changed files with 776 additions and 468 deletions
12
package.json
12
package.json
|
|
@ -25,7 +25,8 @@
|
|||
"eject": "react-scripts eject",
|
||||
"predeploy": "yarn run build",
|
||||
"deploy": "gh-pages -d build",
|
||||
"lint": "eslint src/ --ext .js --fix"
|
||||
"lint": "eslint src/ --ext .js --fix",
|
||||
"pretty": "prettier --single-quote --trailing-comma es5 --write \"src/**/*.js\""
|
||||
},
|
||||
"browserslist": {
|
||||
"production": [
|
||||
|
|
@ -42,8 +43,17 @@
|
|||
"devDependencies": {
|
||||
"babel-eslint": "^10.0.2",
|
||||
"eslint": "^6.1.0",
|
||||
"eslint-plugin-prettier": "^3.1.0",
|
||||
"eslint-plugin-react": "^7.14.2",
|
||||
"husky": "^3.0.5",
|
||||
"prettier": "1.18.2",
|
||||
"pretty-quick": "^1.11.1",
|
||||
"prop-types": "latest",
|
||||
"typescript": "^3.5.3"
|
||||
},
|
||||
"husky": {
|
||||
"hooks": {
|
||||
"pre-commit": "pretty-quick --staged"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue