Skip to content

BlinkStrike/i18n-codemod

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-i18n-codemod

🚀 CLI to automatically parametrize static strings & interpolations in React components for translation.

Install

git clone <repo>
cd react-i18n-codemod
npm install

Usage

npx i18n-codemod <source-folder>

Example:

npx i18n-codemod src/components

What it does

✅ Finds static JSX text & interpolations
✅ Replaces with t('key') or t('key', { param })
✅ Saves translation keys to en.json & he.json
✅ Merges when you re-run

Notes

  • Uses react-i18next. Make sure you load en.json and he.json in your i18n config.
  • Hebrew texts are saved empty to fill later.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published