4.0.2 β€’ Published 1 year ago

@putout/plugin-remove-constant-conditions v4.0.2

Weekly downloads
2,582
License
MIT
Repository
github
Last release
1 year ago

@putout/plugin-remove-constant-conditions NPM version

🐊Putout plugin adds ability to find and remove constant conditions. Merged to @putout/plugin-conditions.

Install

npm i @putout/plugin-remove-constant-conditions -D

Rule

{
    "rules": {
        "remove-constant-conditions": "on"
    }
}

❌ Example of incorrect code

function hi(a) {
    if (2 < 3) {
        console.log('hello');
        console.log('world');
    }
}

βœ… Example of correct code

function hi(b) {
    console.log('hello');
    console.log('world');
}

License

MIT

4.0.1

1 year ago

4.0.2

1 year ago

4.0.0

2 years ago

3.0.1

2 years ago

3.0.0

2 years ago

2.1.0

3 years ago

2.0.0

4 years ago

1.4.1

5 years ago

1.4.0

5 years ago

1.3.0

5 years ago

1.2.0

5 years ago

1.1.0

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago