Skip to content

Commit a1d4ec4

Browse files
committed
Add doc for language weight parameter assignment
1 parent d993a6d commit a1d4ec4

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

content/en/docs/contribute/localization.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,8 +187,11 @@ script and use it in the theme. Assign "language name in latin script" to
187187
`languageNameLatinScript`. For example, `languageNameLatinScript ="Korean"` or
188188
`languageNameLatinScript = "Deutsch"`.
189189

190-
When assigning a `weight` parameter for your block, find the language block with
191-
the highest weight and add 1 to that value.
190+
The `weight` parameter determines the order of languages in the language selection bar.
191+
A lower weight takes precedence, resulting in the language appearing first.
192+
When assigning the `weight` parameter, it is important to examine the existing languages
193+
block and adjust their weights to ensure they are in a sorted order relative to all languages,
194+
including any newly added language.
192195

193196
For more information about Hugo's multilingual support, see
194197
"[Multilingual Mode](https://gohugo.io/content-management/multilingual/)".

0 commit comments

Comments
 (0)