Better localization for multilingual sites #4103
DavidGomez-dev
started this conversation in
Ideas
Replies: 1 comment
-
you can , js add attr
html[lang=zh-hans]{
p:not([lang~=zh-hans]){
display:none
}
}
html:not([lang~=zh-hans]){
p:[lang=zh-hans]{
display:none
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi there,
I am wondering if would make more sense to localizing the labels based on a page variable, such as page.lang and fallback to site.locale
For example, instead of
{{site.data.ui-text[site.locale].categories_label | default: "Categories:" }}
using something like this
{{site.data.ui-text[page.lang].categories_label | default: site.data.ui-text[site.locale].categories_label }}
So, this allows easily to have sites with same pages in different languages.
Beta Was this translation helpful? Give feedback.
All reactions