Closed yanweibj closed 4 years ago
My project will use the same keys in all languages.
For these languages there is no singular/plural distinction. There's only 1 key "rules_0" This is how the plural rules work in i18next. So you need to add the key "rules_0" for zh for example and no rules + rules_plural
https://www.i18next.com/translation-function/plurals#languages-with-multiple-plurals same rule for languages not having pluralforms
Thank you all.
https://www.i18next.com/translation-function/plurals
We have a project that support muti-languages. And we use { "keyWithCount": "{{count}} item", "keyWithCount_plural": "{{count}} items" }
It works well for en/fr/de. count = 1 return "key" count = 2,3,4... return "key_plural"
But for ja/ko/zh-cn/zh-tw. the code will return "key_0" no matter the count is.
My code is like this: rules: {{count}} rule rules_pural: {{count}} rules
For ja/ko/zh-cn/zh-tw, It will use "rules: {{count}} rule" as it can't find key "rules_0".
Please help to advise how to solve my problem.