@clearkit/codemods

0.104.2-alpha.0 • Public • Published

Codemods

Install codemods

No need to install codemods. They can be run with npx.

Run codemods

Run each codemod on a given directory. In the example below, the codemod is run against all files in /client/src using the v1-imports transform:

Important note on node versions

Codemods will only run in Node v18 due to a limitation of jscodeshift. Run codemods in a separate terminal window/tab and run nvm use before running codemods. If you haven't installed node 18, you will need to run nvm install 18 first/

nvm use 18

Run codemod

The arguments are the relative directory to run the codemod in and the name of the codemod. For example, the directory is client/src and the codemod is v1-imports:

npx @clearkit/codemods client/src v1-imports
npx @clearkit/codemods client/src v1-buttons

Available codemods for v1

  • v1-buttons
  • v1-imports
  • v1-imports-icons
  • v1-popper
  • v1-popper-options
  • v1-toggle-props

Readme

Keywords

none

Package Sidebar

Install

npm i @clearkit/codemods

Weekly Downloads

0

Version

0.104.2-alpha.0

License

MIT

Unpacked Size

57.2 kB

Total Files

11

Last publish

Collaborators

  • zsteiner
  • rebeccayang
  • justin-clearbit
  • maccman
  • mginnard
  • joaomdmoura
  • davidlumley
  • wadetandy
  • gvieira37