configure husky and lint-staged
This commit is contained in:
parent
8e88fd14e1
commit
3b91ef6474
|
@ -0,0 +1,4 @@
|
|||
#!/usr/bin/env sh
|
||||
. "$(dirname -- "$0")/_/husky.sh"
|
||||
|
||||
npx lint-staged
|
11
package.json
11
package.json
|
@ -6,14 +6,13 @@
|
|||
"dev": "next dev",
|
||||
"build": "next build",
|
||||
"start": "next start",
|
||||
"lint": "next lint"
|
||||
"lint": "next lint",
|
||||
"prepare": "husky install"
|
||||
},
|
||||
"lint-staged": {
|
||||
"src/**/*.{ts,tsx}": [
|
||||
"eslint --ext .tsx,ts src/ --fix"
|
||||
],
|
||||
"src/**": [
|
||||
"prettier --check 'src/**/*.ts' 'src/**/*.tsx'"
|
||||
"*.{ts,tsx}": [
|
||||
"prettier --write",
|
||||
"eslint --fix"
|
||||
]
|
||||
},
|
||||
"husky": {
|
||||
|
|
Loading…
Reference in New Issue