diff --git a/js/.gitignore b/js/.gitignore index acb73a82a..c1e496d91 100644 --- a/js/.gitignore +++ b/js/.gitignore @@ -6,3 +6,4 @@ build .dist .happypack .npmjs +.eslintcache diff --git a/js/package.json b/js/package.json index eb0926c4b..e7ba88e74 100644 --- a/js/package.json +++ b/js/package.json @@ -39,9 +39,11 @@ "clean": "rm -rf ./build ./coverage", "coveralls": "npm run testCoverage && coveralls < coverage/lcov.info", "lint": "eslint --ignore-path .gitignore ./src/", + "lint:cached": "eslint --cache --ignore-path .gitignore ./src/", "test": "mocha 'src/**/*.spec.js'", "test:coverage": "istanbul cover _mocha -- 'src/**/*.spec.js'", - "test:e2e": "mocha 'src/**/*.e2e.js'" + "test:e2e": "mocha 'src/**/*.e2e.js'", + "prepush": "npm run lint:cached" }, "devDependencies": { "babel-cli": "^6.10.1", @@ -84,6 +86,7 @@ "happypack": "^2.2.1", "history": "^2.0.0", "html-loader": "^0.4.4", + "husky": "^0.11.9", "ignore-styles": "2.0.0", "image-webpack-loader": "^1.8.0", "istanbul": "^1.0.0-alpha.2",