is-even Codemod
Introduction
This codemod removes the dependency on the is-even
npm module by replacing its usage with a native JavaScript expression that checks if a number is even. This change optimizes performance, reduces bundle size, and eliminates unnecessary dependencies.
Before
import isEven from 'is-even';const result = isEven(4);
After
const result = (4 % 2) === 0;
Build custom codemods
Use AI-powered codemod studio and automate undifferentiated tasks for yourself, colleagues or the community