prelint
v1.2.0
Published
preLint passes your git staged files through ESLint utility
Downloads
4
Maintainers
Readme
preLint
preLint passes your git staged files through ESLint utility.
Shines with pre-commit module.
Requirements
- NodeJS 6+ and npm installed
Installation
$ npm install prelint --save-dev
Usage
- Add the
lint
command to thescripts
section of yourpackage.json
like this:"lint": "./node_modules/.bin/prelint",
- Install pre-commit module
npm install --save-dev pre-commit
- Add
precommit
section to yourpackage.json
- Add
lint
task toprecommit
section
Example
package.json
{
...
"scripts": {
...
"lint": "./node_modules/.bin/prelint",
...
},
"precommit": [
...
"lint",
...
],
...
}