Codemods for migration to the newer version of the @volue/wave-react
library.
These codemods utilize jscodeshift library for transformations and Hypermod.io CLI tool for downloading and running them against your codebase.
No installation of this package is necessary.
Downloading and running codemods can be done via npx @hypermod/cli
.
- You should run codemods on a separate Git branch, then manually review the changes before deploying them.
- Codemods are designed to do the heavy lifting, but they may not be perfect, so some manual work may still be required in order to successfully migrate.
- Codemods might output code that doesn’t follow your coding style. Make sure to run your code formatter and/or linter before committing the changes.
To run a transform for version 1.0.0
of @volue/wave-react
, use one of the following commands:
# Transform multiple files
npx @hypermod/cli --packages @volue/wave-codemod__react@1.0.0 /project/src/**/*.tsx
# Transform single file
npx @hypermod/cli --packages @volue/wave-codemod__react@1.0.0 /project/src/path/to/file
To run all transforms for @volue/wave-react
in sequence from version 1.0.0
to the latest, add --sequence
flag:
npx @hypermod/cli --sequence --packages @volue/wave-codemod__react@1.0.0 /project/src/**/*.tsx