A collection of eslint rules.
You'll first need to install ESLint:
$ npm i eslint --save-dev
Next, install eslint-plugin-pocket-fluff
:
$ npm install eslint-plugin-pocket-fluff --save-dev
Note: If you installed ESLint globally (using the -g
flag) then you must also install eslint-plugin-pocket-fluff
globally.
Add pocket-fluff
to the plugins section of your .eslintrc
configuration file. You can omit the eslint-plugin-
prefix:
{
"plugins": ["pocket-fluff"]
}
Then configure the rules you want to use under the rules section in your .eslintrc file.
{
"rules": {
"pocket-fluff/no-jsx-spread": "error",
"pocket-fluff/no-dead-code": "error"
}
}
Disallow the use of the JSX spread for perf and DX reasons. README
Disallow code past its marked @removeby. README
Disallow Reassignments of consts and Const-named variables. README
Disallow reassigning external variables from inside react components. README
Disable octal, hex, and boolean numeric literals. README