React

Introduction

@seed-design/codemod is a code transformation tool for migrating from Sprout to Crispy.

Usage

npx @seed-design/codemod@latest <transform> <target_path> <options>

To check the list of available transforms, run the following command.

npx @seed-design/codemod@latest --list

Available Transforms

Check the list of available transformations.

Node.js Requirements

Node.js version 20.19.0 or higher is required to run the script. A message will be displayed if the version requirements are not met.

If you use nvm, you can temporarily change the Node.js version to run codemod.

nvm install 20.19

Options

  • --list
    • Shows the list of available transforms.
  • --log
    • Saves logs to a file.
    • combined.log and warnings.log files are created in ./.
  • --parser
    • Specifies the parser for jscodeshift to use.
    • babel | babylon | flow | ts | tsx
    • Default: tsx
    • Example: --parser=babel
  • --extensions
    • Specifies the file extensions to transform.
    • If not specified, transforms js,jsx,ts,tsx files in <path>. (d.ts is excluded)
    • Example: --extensions="ts,tsx"
  • --ignore-config
    • Specifies a file that defines file patterns to not transform.
    • Example: --ignore-config=".gitignore"

Table of contents