Open pklebba opened 8 years ago
Hi,
I wasn't aware of these problems in the standard Lang
package, if it doesn't support those required features, we will have to look elsewhere for definite. Thanks for bringing it to our attention!
That's great, thanks! 😄
My friend made that package for Laravel for better language support than built in solution: https://github.com/Skysplit/laravel5-intl-translation
You can say, why? So, currently it is impossible to properly format plural rules in many languages, as in some languages' rules are not just ranges, but often require modulo operations etc.
MessageFormatter
allows it.For example, let's use Polish word "miesiąc" (means "month"):
More here: http://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html#pl
It's not possible to correctly implement that word in built in Laravel's package. In English language it's not a problem, because here we have just two options:
month
andmonths
. But there's a problem for Polish, Russian, Arabic and many more. That's why I think it should be taken into consideration.He's working on it in official Laravel repository: https://github.com/laravel/internals/issues/160