eslint-plugin
Custom or changed ESLint rules for "Pac Group" projects.
Installation
You'll first need to install ESLint:
$ npm install eslint --save-dev
Next, install @pacgroup/eslint-plugin
:
$ npm install @pacgroup/eslint-plugin --save-dev
Note: If you installed ESLint globally (using the -g
flag) then you must also install @pacgroup/eslint-plugin
globally.
Usage
Add @pacgroup
to the plugins section of your .eslintrc
configuration file. You can omit the /eslint-plugin
suffix.
You can either enable individual rules as follows:
{
"plugins": [
"@pacgroup"
],
"rules": {
"@pacgroup/curly": "error"
}
}
Or you can use the full set of rules:
{
"plugins": [
"@pacgroup"
],
"extends": [
"plugin:@pacgroup/all"
]
}
Development
npm install
npm test