Shopify / shopify-app-template-node

MIT License
867 stars 391 forks source link

Internationalize Node app template #1266

Closed trishrempel closed 1 year ago

trishrempel commented 1 year ago

WHY are these changes introduced?

Translating apps is technically challenging, time-consuming, and costly. Despite the high demand for localized apps internationally, only a small fraction of apps offered in the Shopify App Store are translated.

None of Shopify's app templates are localized, meaning that the full burden of responsibility is on the developer to research and implement an i18n framework for their app. It’s also more likely to be an afterthought until the developer decides to expand internationally, at which point the effort to externalize all the app's strings is much higher.

By localizing the default Node app template, we reduce the toil for developers, and set them up to localize their apps from the start.

WHAT is this pull request doing?

English:

Screenshot 2023-05-24 at 10 25 02 AM

French:

Screenshot 2023-05-24 at 10 24 08 AM

German:

Screenshot 2023-05-24 at 10 24 35 AM

How to test

npm init @shopify/app@latest -- --template https://github.com/shopify/shopify-app-template-node#add-i18next
npm run build
npm run dev

Checklist

Note: once this PR is merged, it becomes a new release for this template.

trishrempel commented 1 year ago

⚠️ Moving back to draft; I noticed some issues with loading dynamic imports that weren't a problem last week.