-
Notifications
You must be signed in to change notification settings - Fork 17
Migrate i18next-parser to i18next-cli #452
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
WalkthroughThe pull request migrates the i18n tooling from i18next-parser to i18next-cli. It replaces the old parser configuration file with a new TypeScript-based CLI configuration, updates related package dependencies in two package.json files, and adjusts the extraction script command accordingly. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
87107fb to
2a088ad
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
package.json (1)
44-44: Consider updating i18next-cli to a more recent stable version.The specified version ^1.5.11 is significantly outdated; the latest stable release is v1.33.5. While the caret operator will allow npm to install newer 1.x releases automatically, explicitly targeting a more recent version like ^1.33.5 would be clearer and ensure the latest features and improvements are captured. No known security vulnerabilities were found for v1.5.11.
📜 Review details
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
package-lock.jsonis excluded by!**/package-lock.json
📒 Files selected for processing (5)
libs/i18n/i18next-parser.config.jslibs/i18n/i18next.config.tslibs/i18n/locales/en/translation.jsonlibs/i18n/package.jsonpackage.json
💤 Files with no reviewable changes (1)
- libs/i18n/i18next-parser.config.js
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: integration-tests
- GitHub Check: Lint
🔇 Additional comments (4)
libs/i18n/package.json (1)
10-10: Simplified extraction script looks good.The new script is cleaner and the git diff check ensures translation files are kept in sync during CI runs.
libs/i18n/i18next.config.ts (3)
5-13: Extract configuration is well-structured.The input path pattern correctly targets all workspace source files, and the extraction settings (functions, transComponents, separators) cover standard i18next usage patterns appropriately.
14-17: Type generation is a valuable addition.The types configuration will generate TypeScript declarations from translation files, providing type safety for translation keys—a significant improvement over i18next-parser.
1-3: No issues found. ThedefineConfigimport and usage pattern is correct and follows the official i18next-cli API.
i18next-parseris now deprecated and bringing some old dependencies.Run
npx i18next-cli migrate-config i18next-parser.config.jsto correctly migrate the config file.Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.