-
-
Notifications
You must be signed in to change notification settings - Fork 483
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
feat: extend lazy loading #1801
Conversation
|
||
This is useful because it is efficient to manage multiple files that define only differences without duplicating locale messages. | ||
|
||
For example, letβs think for the case of Spanish language supporting. There are **79 Spanish-speaking countries** according to [wikipedia](https://en.wikipedia.org/wiki/Spanish_language)! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
19 countries listed on ISO (official): only these https://github.com/elk-zone/elk/pull/1172/files#diff-fb2fd6012fe1954c1021496a3bc2260acb3878612e64f1e0dbdbf30862bbf8f8R93
There are also a few countries on what spanish was official but no rn: Filipinas for example
https://es.wikipedia.org/wiki/Anexo:Pa%C3%ADses_donde_el_espa%C3%B1ol_es_idioma_oficial
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still 79, it should be 19, read the article again, these are estimated people who speak Spanish in those countries: in Spain there are people who speak Japanese but in Spain Japanese is not official, you don't have to count Spain as countries speaking japanese ;)
Check Geographical distribution
, it just mention 20 countries, you're using Spanish speakers by country
entry.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
upps (updated to 15), why showing changes shows previouws version?
|
||
In the above `es-AR` example, it has `es.json` and `es-AR.json` into `files`. In this case, @nuxtjs/i18n lazy-load `es.json`, and the it lazy-load `es-AR.json` and overrides for `es.json` locale messages. | ||
|
||
In the example above, only two files are defined for `files`, ofcourse you can specify more files over 2 files. In that case, the files will be loaded and override in array order too. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wording: of course
(space)
@userquin |
* feat: extend lazy loading resolve nuxt-modules#1797 * feat: extend lazy loading resolve nuxt-modules#1797 * update nuxt module * update playground * remove settings * add docs * update docs * update docs * update testing * docs: tweak
resolve #1797
π Linked issue
β Type of change
π Description
π Checklist