Simplify boolean literal comparisons

Proprietary

Removes redundant comparisons against boolean literals. For example, x === true becomes x and x === false becomes !x. Handles both strict (===/!==) and loose (==/!=) equality, where the operand is known to be a boolean.

org.openrewrite.javascript.cleanup.SimplifyBooleanLiteral
mod run . --recipe=org.openrewrite.javascript.cleanup.SimplifyBooleanLiteral

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.