Skip to content

Commit

Permalink
add pre-commit hook to run prettier before commit
Browse files Browse the repository at this point in the history
  • Loading branch information
TobiasPr committed Dec 22, 2020
1 parent f248228 commit 62c5cbb
Show file tree
Hide file tree
Showing 2 changed files with 229 additions and 1 deletion.
11 changes: 11 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,15 @@
"publish:minor": "yarn prepare && yarn test && yarn copyAPIToDoc && npm version minor && npm publish",
"publish:major": "yarn prepare && yarn test && yarn copyAPIToDoc && npm version major && npm publish"
},
"husky": {
"hooks": {
"pre-commit": "lint-staged"
}
},
"lint-staged": {
"*.ts": "stylelint --fix",
"*.{ts,tsx,js,css,md}": "prettier --write"
},
"dependencies": {
"is-mobile": "2.2.2",
"pepjs": "0.5.2",
Expand Down Expand Up @@ -65,8 +74,10 @@
"fork-ts-checker-notifier-webpack-plugin": "3.0.0",
"fork-ts-checker-webpack-plugin": "6.0.4",
"html-webpack-plugin": "4.5.0",
"husky": "4.3.6",
"jest": "26.6.3",
"jest-styled-components": "7.0.3",
"lint-staged": "10.5.3",
"prettier": "2.2.1",
"redux-mock-store": "1.5.4",
"style-loader": "2.0.0",
Expand Down
Loading

0 comments on commit 62c5cbb

Please sign in to comment.