eslint-plugin-no-unnecessary-boolean-cast

0.0.1 • Public • Published

eslint-plugin-no-unnecessary-boolean-cast

Typescript eslint rule disallowing calling Boolean function cast when the result will be always the same

Installation

You'll first need to install ESLint:

$ npm i eslint --save-dev

Next, install eslint-plugin-no-unnecessary-boolean-cast:

$ npm install eslint-plugin-no-unnecessary-boolean-cast --save-dev

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

Usage

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

{
    "plugins": [
        "no-unnecessary-boolean-cast"
    ]
}

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

{
    "rules": {
        "no-unnecessary-boolean-cast/rule-name": 2
    }
}

Supported Rules

  • Fill in provided rules here

/eslint-plugin-no-unnecessary-boolean-cast/

    Package Sidebar

    Install

    npm i eslint-plugin-no-unnecessary-boolean-cast

    Weekly Downloads

    1

    Version

    0.0.1

    License

    ISC

    Unpacked Size

    7.29 kB

    Total Files

    10

    Last publish

    Collaborators

    • tomastauer