Micro-frontends are localized by utilizing frontend-platform/i18n and transifex.
Localized MFE message strings live in src/i18n
(see frontend-template-application/src/i18n)
The transifex source file (transifex_input.json)
is generated by running make extract_translations
(see frontend-template-application/Makefile)
Work is being done to simplify and modernize the translation flow, see Instructions (modernized) (WIP) |
Ensure all strings in the MFE are utilizing i18n (example) (more details here: Internationalize your application with react-intl and here: https://openedx.atlassian.net/wiki/spaces/LOC/pages/3103293538/MFE+Translation+How+To+s#How-to-internationalize-your-React-App)
Check if the MFE is already set up to automatically pull translations from transifex (look for commits that say chore(i18n)
from edx-transifex-bot) (example)
If the MFE is already using the bot you should be all set by simply adding messages to the source files in src/i18n
If the MFE is not using the bot you can still extract/push/pull translations manually (also see Set up Transifex)
The transifex cli usage is being replaced by the transifex github app |
Ensure all strings in the MFE are utilizing i18n (example) (more details here: Internationalize your application with react-intl and here: https://openedx.atlassian.net/wiki/spaces/LOC/pages/3103293538/MFE+Translation+How+To+s#How-to-internationalize-your-React-App)
Ensure running make extract_translations
properly generates transifex_input.json
Update js-translations
in extract-translation-source-files.yml on the openedx-translations repo to include the MFE
Update transifex.yml on the openedx-translations repo to include the MFE
Wait for openedx-atlas development to reach a stage where translations are automatically pushed back to the MFE