eslint-plugin-f
v1.1.1
Published
misc eslint rules
Downloads
11
Maintainers
Readme
eslint-plugin-f
Miscellanous Eslint rules for Javascript and React projects.
Installation
You'll first need to install ESLint:
npm i eslint -Dor
yarn add eslint -DNext, install eslint-plugin-f:
npm install eslint-plugin-f -Dor
yarn add eslint-plugin-f -DUsage
Add f (oreslint-plugin-f) to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:
{
"plugins": [
"f"
]
}Then configure the rules you want to use under the rules section.
{
"rules": {
"f/rule-name": 2
}
}List of supported rules
✔: Enabled in the recommended configuration.
🔧: Fixable with eslint --fix.
| ✔ | 🔧 | Rule | Description | | :---: | :---: | :--- | :--- | | ✔ | | f/ensure-matching-remove-event-listener | Enforces that every addEventListener should have a matching removeEventListener in the same useEffect block | | ✔ | | f/no-useless-assignment | Disallow the reassignment of a variable that was declared in the immediately previous line. |
License
eslint-plugin-f is licensed under the MIT License.
