vue-i18n
vue-i18n copied to clipboard
Support fetching locales from api
Clear and concise description of the problem
If I understand the docs correctly, it's only possible to lazy load other locales via dynamic import: https://vue-i18n.intlify.dev/guide/advanced/lazy.html
This doesn't work for me because I don't have any json files but rely on getting the translations from an api. Furthermore I've got a lot of translations any don't wanna import everything for a given language but only load specific namespaces.
Suggested solution
Support namespaces to avoid loading all translations (similar to i18next) and support fetching via http request (similar to https://github.com/i18next/i18next-http-backend)
Alternative
Only alternative I can image (without using another framework) is downloading all data from the api in the (webpack) build process and emit it as json files though this would feel quite hacky and doesn't solve the namespace issue.
Additional context
No response
Validations
- [X] Read the Contributing Guidelines
- [X] Read the Documentation
- [X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
Something similar to this?