Skip to content

Enable string extraction tooling (e.g. i18n-extract) to surface missing or new keys to translate #22606

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

Open
3 tasks
churik opened this issue May 19, 2025 · 1 comment

Comments

@churik
Copy link
Member

churik commented May 19, 2025

Problem

There’s no automated way to detect new or missing translation keys, which makes it easy to overlook untranslated content. A string extraction tool will help maintain complete and consistent language files.

Requires DevOps input.

Implementation

  • Integrate i18n-extract (or equivalent) into the build or CI process
  • Configure it to compare source code usage vs. existing translation files
  • Output a report of missing or unused keys

Acceptance Criteria

  • Tool can detect missing keys based on source usage
  • Tool does not introduce breaking changes to build
  • Report can be used to update en.json and sync with Crowdin

Notes

  • Keep the tool optional in local dev flow but required in CI.
  • Useful as a QA and dev support tool before translation syncs.

Future Steps

  • Automate pushing extracted source keys to Crowdin
  • Use the report to flag regressions in i18n coverage
@ilmotta
Copy link
Contributor

ilmotta commented May 19, 2025

There’s no automated way to detect new or missing translation keys

We already have a linter written in CLJS to detect missing translation keys in the file scripts/lint/translations.clj but it focuses on the en.json file. There's no 100% deterministic way to detect all keys because IIRC there are a few cases where the keys are dynamic and can't be detected by the simple :t/* keyword convention, so this requirement deserves to be evaluated because it may not be feasible without significant changes.

That CLJS script could, in theory, evolve to cover our new needs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

No branches or pull requests

2 participants