garikkh

Results 21 comments of garikkh

The main reason is for my TMS - there are times the `-` in the prefix causes issues, either when showing the comments or parsing them into separate lines. i.e....

> `. js-lingui-explicit-id` should also break your TMS, isn't it? No, because it breaks in my TMS only because of the line length. PO files are recommended to split on...

Supporting line split comments is nontrivial as well, for cases like this: ``` #. some other comment #. js- #. lingui:pluralize_on=someCount #. js- #. lingui-explicit-id msgid "message_with_id" msgid_plural "message_with_id_plural" msgstr[0]...

@timofei-iatsenko can I get your review on this? Is there anything else I should add to get this merged?

Might have to warn or hard error on `compile` if the msgstr does not match with nplurals header - for example: ```po msgid "" msgstr "" "Language: fr\\n" "Plural-Forms: nplurals=3;...

Also some uncaught runtime errors if the locale isn't found in the cldr plurals lib. Probably needs a cleaner error message, and also specifically for `pseudo` case. Following [this guide](https://lingui.dev/guides/pseudolocalization)...

Most likely I will have some time this week to take over this PR.

Had a few fixes here: https://github.com/timofei-iatsenko/js-lingui/compare/feature/respect-plural-forms-header...garikkh:js-lingui:feature/respect-plural-forms-header tested the PO files my TMS generates, looks good. One thing to note is that because the library uses `Intl.PluralRules` it technically isn't going...

@andrii-bodnar I linked a PR I made with @timofei-iatsenko fork as the base branch, just so it was a tiny bit neater. Wasn't sure if you guys wanted a separate...

More details: cldr-data is a great repository, but the plurals data is difficult to parse. each language has plurals defined like this: ```json "cs": { "pluralRule-count-one": "i = 1 and...