-
-
Notifications
You must be signed in to change notification settings - Fork 215
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
Vue internationalization choices? #11111
Comments
At first, I made a version with only multiple json files but the tradeoff doing that is you need to specify the namespace each time you want to translate (eg the name of the json file). So after discussions with @Gnuk, we found that using namespace was too verbose. Plus with typescript files, you declare you translation scoped to the context. You don't need to get the json file from the assets when you export the context. Both solutions are working just need to decide the better for our needs. |
I think you can merge multiple json files without namespace
|
Yes, I think it's possible, maybe also using ts instead of JSON with something like import meta glob or async import. I think that the first proposition used explicit import because the use case was without a lot of files to import. I think there is an interesting idea with ts if we can be able to get type form a default translation file to force other translations to respect the type (using things like |
Playing with
vue-i18next
module I have some questions on the choices that were made:I was expecting something to just drop json files somewhere in context to get translations for the context and I'm confused with the tradeoffs :D. cc @fabienpuissant
The text was updated successfully, but these errors were encountered: