From 4de2fafcad4b56449e3817825d4b317c5ed4696c Mon Sep 17 00:00:00 2001 From: Rigel Kent Date: Sat, 12 May 2018 17:28:37 +0200 Subject: added linter and prettifier via commit hooks --- package.json | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'package.json') diff --git a/package.json b/package.json index ac0703eb9..94cda5ef8 100644 --- a/package.json +++ b/package.json @@ -47,11 +47,25 @@ "nodemon": "nodemon", "ts-node": "ts-node", "tslint": "tslint", + "sasslint": "sass-lint --verbose --no-exit", + "sasslint:fix": "sass-lint-auto-fix -c .sass-lint.yml --verbose", "mocha": "mocha", "travis": "scripty", "release": "scripty", "client-report": "scripty" }, + "husky": { + "hooks": { + "pre-commit": "lint-staged" + } + }, + "lint-staged": { + "*.{js,ts,css,md}": "precise-commits", + "*.scss": [ + "sass-lint-auto-fix -c .sass-lint.yml --verbose", + "git add" + ] + }, "dependencies": { "async": "^2.0.0", "async-lru": "^1.1.1", @@ -134,11 +148,17 @@ "chai": "^4.1.1", "chai-json-schema": "^1.5.0", "chai-xml": "^0.3.2", + "husky": "^1.0.0-rc.4", "libxmljs": "^0.18.7", + "lint-staged": "^7.1.0", "maildev": "^1.0.0-rc3", "mocha": "^5.0.0", "nodemon": "^1.11.0", + "precise-commits": "^1.0.2", + "prettier": "1.12.1", "prompt": "^1.0.0", + "sass-lint": "^1.12.1", + "sass-lint-auto-fix": "^0.9.0", "source-map-support": "^0.5.0", "spectacle-docs": "^1.0.2", "supertest": "^3.0.0", -- cgit v1.2.3