tech: added prettier to precommit

This commit is contained in:
Torkel Ödegaard
2017-12-19 13:27:05 +01:00
parent 0d9378d18e
commit 75bb511019
3 changed files with 113 additions and 53 deletions
+12 -2
View File
@@ -65,7 +65,7 @@
"karma-sinon": "^1.0.5",
"karma-sourcemap-loader": "^0.3.7",
"karma-webpack": "^2.0.4",
"lint-staged": "^4.2.3",
"lint-staged": "^6.0.0",
"load-grunt-tasks": "3.5.2",
"mocha": "^4.0.1",
"ng-annotate-loader": "^0.6.1",
@@ -103,7 +103,17 @@
"lint": "tslint -c tslint.json --project tsconfig.json --type-check",
"karma": "node ./node_modules/grunt-cli/bin/grunt karma:dev",
"jest": "node ./node_modules/jest-cli/bin/jest.js --notify --watch",
"precommit": "node ./node_modules/grunt-cli/bin/grunt precommit"
"precommit": "lint-staged && node ./node_modules/grunt-cli/bin/grunt precommit"
},
"lint-staged": {
"*.{ts,tsx}": [
"prettier --write",
"git add"
],
"*.scss": [
"prettier --write",
"git add"
]
},
"license": "Apache-2.0",
"dependencies": {