Push down negation

Push the not-operator (!) into an expression and negate it.

Push down negation

Why is this refactoring helpful?

Push negation into an expression can simplify code, either directly or by enabling the removal of double negation.

What do I need to consider?

When the operator is <, <=, > or >= the result for NaN and nullish values can change.

Configuration

Related Code Assists

Learn More

Available In