lephyrus / ngx-translate-messageformat-compiler

Advanced pluralization (and more) for ngx-translate, using standard ICU syntax which is compiled with the help of messageformat.js.
MIT License
93 stars 29 forks source link

Problems, with ICU #59

Closed neverlose-lv closed 4 years ago

neverlose-lv commented 4 years ago

Translation is not working for me, when I use the few ICU expression:

{
    "test": "{ticketsCount, plural, one{остался} few{осталось} other{осталось}}
}

if I remove few{осталось}

{
    "test": "{ticketsCount, plural, one{остался} other{осталось}}
}

then the translation and pluralization works great.

Adding the disablePluralKeyChecks: true, to the config, solves the problem. But I don't understand why the key few is invalid? It is the ICU standard, which I need.

neverlose-lv commented 4 years ago

Ok, I understood, this depends on the selected language.