0.1.1 • Published 4 years ago

eslint-plugin-no-duplicate-else v0.1.1

Weekly downloads
-
License
ISC
Repository
-
Last release
4 years ago

eslint-plugin-no-duplicate-else

this plugin provides a new rules which enforce no duplicate else

Installation

You'll first need to install ESLint:

$ npm i eslint --save-dev

Next, install eslint-plugin-no-duplicate-else:

$ npm install eslint-plugin-no-duplicate-else --save-dev

Note: If you installed ESLint globally (using the -g flag) then you must also install eslint-plugin-no-duplicate-else globally.

Usage

Add no-duplicate-else to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:

{
    "plugins": [
        "no-duplicate-else"
    ]
}

Then configure the rules you want to use under the rules section.

{
    "rules": {
        "no-duplicate-else/rule-name": 2
    }
}

Supported Rules

no-dupe-else-if