Skip to content

chore(i18n): Commit locale JS and drop properties - #783

Open
jackiejou wants to merge 1 commit into
box:masterfrom
jackiejou:chore/i18n-committed-locale-js
Open

chore(i18n): Commit locale JS and drop properties#783
jackiejou wants to merge 1 commit into
box:masterfrom
jackiejou:chore/i18n-committed-locale-js

Conversation

@jackiejou

Copy link
Copy Markdown
Collaborator

Summary

  • Committed per-locale i18n/{locale}.js maps and pointed webpack at those files
  • Removed props2es, babel-plugin-react-intl, and TranslationsPlugin
  • Added yarn extract:i18n via @formatjs/cli
  • Deleted tracked .properties files so the localization job switches to formatjs extract

Why

This repo already used react-intl in source. The remaining work was the Legacy to New Mode pipeline cutover: locale JS is the runtime source, and deleting .properties is the signal for the localization job to extract from defineMessages and recommit locale files.

The committed JS files are a seed from the last properties conversion. The next localization run will overwrite them in the job format (empty en-US.js, generated-file banner on other locales).

Test plan

  • yarn extract:i18n matches all 22 source strings
  • Production webpack build succeeds
  • 1072 unit tests pass
  • EndUserApp portal resolves box-annotations/i18n/en-US and loads the 22 keys
  • Open a document in a linked host, draw a region, and confirm annotation copy still renders

Locale maps are now tracked under i18n/{locale}.js. Webpack and
createIntl read those files. formatjs extract replaces the Babel
plugin. Removing properties switches the localization job to New Mode.
@jackiejou
jackiejou requested a review from a team as a code owner September 12, 2026 00:25
@socket-security

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Added@​formatjs/​cli@​6.16.26991006898100

View full report

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant