You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to make floating numbers to work with plurals translation. Was looking for a while and then realized that library doesn't support it at this point. I pulled "make-plural" library and if I pass 0.5 it returns "other" which makes sense, but i18nTranslatePlural MakePlural returns "many". After digging a bit more, I found that it happens because of parseInt statement on line 358 in i18n.js (so 0.5 becomes 0 -> "many").
If it makes sense to change from parseInt to parseFloat I will be happy to make this change.
I have in JSON:
"%s tablespoon": {
"one": "столовая ложка",
"few": "столовых ложки",
"many": "столовых ложек",
"other": "столовой ложки"
}
The text was updated successfully, but these errors were encountered:
I'm trying to make floating numbers to work with plurals translation. Was looking for a while and then realized that library doesn't support it at this point. I pulled "make-plural" library and if I pass 0.5 it returns "other" which makes sense, but i18nTranslatePlural MakePlural returns "many". After digging a bit more, I found that it happens because of parseInt statement on line 358 in i18n.js (so 0.5 becomes 0 -> "many").
If it makes sense to change from parseInt to parseFloat I will be happy to make this change.
I have in JSON:
"%s tablespoon": {
"one": "столовая ложка",
"few": "столовых ложки",
"many": "столовых ложек",
"other": "столовой ложки"
}
The text was updated successfully, but these errors were encountered: