Skip to content

Commit 4f39f33

Browse files
author
Pavel Ivanoff
committed
test: setup husky
1 parent 66f34b7 commit 4f39f33

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

package.json

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@
66
"module": "index.js",
77
"scripts": {
88
"lint": "eslint --fix index.js",
9-
"pretest": "npm run lint",
10-
"test": "jest"
9+
"pretest": "yarn lint",
10+
"test": "jest",
11+
"prepublish": "yarn test"
1112
},
1213
"dependencies": {
1314
"react-use": "2.2.0",
@@ -18,6 +19,7 @@
1819
"eslint": "^5.8.0",
1920
"eslint-config-airbnb-base": "^13.1.0",
2021
"eslint-plugin-import": "^2.14.0",
22+
"husky": "^1.1.2",
2123
"jest": "^23.6.0",
2224
"mocha": "^5.2.0",
2325
"rollup": "^0.66.6"
@@ -26,6 +28,11 @@
2628
"react": "^16.7.0-alpha.0",
2729
"react-dom": "^16.7.0-alpha.0"
2830
},
31+
"husky": {
32+
"hooks": {
33+
"pre-push": "yarn test"
34+
}
35+
},
2936
"keywords": [
3037
"react-hooks",
3138
"react-hook",

0 commit comments

Comments
 (0)