You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@putout/plugin-simplify-boolean-return

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@putout/plugin-simplify-boolean-return

🐊Putout plugin adds ability to simplify boolean return

1.0.0
Source
npmnpm
Version published
Weekly downloads
3.2K
10.6%
Maintainers
1
Weekly downloads
 
Created
Source

@putout/plugin-simplify-boolean-return NPM version

🐊Putout plugin adds ability to simplify boolean return.

Install

npm i @putout/plugin-simplify-boolean-return -D

Rule

{
    "rules": {
        "simplify-boolean-return": "on"
    }
}

Check out in 🐊Putout Editor.

❌ Example of incorrect code

function isA(a, b) {
    if (a.length !== b.length)
        return false;
    
    return true;
}

✅ Example of correct code

function isA(a, b) {
    return a.length !== b.length;
}

License

MIT

Keywords

putout

FAQs

Package last updated on 13 Jun 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts