Added husky
This commit is contained in:
parent
9e242ddf5d
commit
2c7c5c7d5c
5
.husky/pre-commit
Executable file
5
.husky/pre-commit
Executable file
@ -0,0 +1,5 @@
|
||||
#!/usr/bin/env sh
|
||||
. "$(dirname -- "$0")/_/husky.sh"
|
||||
|
||||
npm run format
|
||||
npm run lint
|
@ -74,14 +74,16 @@
|
||||
"webpack-bundle-analyzer": "4.7.0",
|
||||
"webpack-cli": "^5.0.1",
|
||||
"webpack-dev-server": "4.11.1",
|
||||
"webpack-merge": "5.8.0"
|
||||
"webpack-merge": "5.8.0",
|
||||
"husky": "^8.0.0"
|
||||
},
|
||||
"scripts": {
|
||||
"build": "cross-env SERVE=true webpack -c config/webpack/prod.js",
|
||||
"start": "webpack serve -c config/webpack/dev.js",
|
||||
"analyze": "webpack --analyze -c config/webpack/analyze.js",
|
||||
"format": "prettier --write \"./**/*.{js,jsx}\"",
|
||||
"lint": "npx eslint 'src/**/*.{js,jsx,ts,tsx}'"
|
||||
"lint": "npx eslint 'src/**/*.{js,jsx,ts,tsx}'",
|
||||
"prepare": "husky install"
|
||||
},
|
||||
"eslintConfig": {
|
||||
"extends": [
|
||||
|
Loading…
Reference in New Issue
Block a user