social-app
social-app copied to clipboard
Replace pluralize() with plural() or <Plural> to make some UI elements translatable.
- Replace all pluralize (defined by src/lib/strings/helpers.ts) with plural or Plural (defined by @lingui/macro) to make some UI elements translatable.
- Delete pluralize() and related test.
Going to review in a bit but going to drop in -- I tried this previously and hit some strange compile issues. Forget the details but need to be sure this is tested on all platforms
I tested this patch only on my Ubuntu 22.04.3 environment by 'yarn web'.
I setup Android dev environment and tested and got error.
Calling new Intl.PluralRules(...)
inside plural()
produced TypeError: Cannot read property 'prototype' of undefined
error.
I found in lingui document that React Native doest not support Intl.PluralRules
API, so plural()
/ <Plural>
doest not work correctly.
Updated this PR for Android and iOS platform (tested on Android/iOS emulators).
Hi @pfrazee , is there any problem that prevents the development team from merging this PR into the main, as we need to l10n some parts of the UI properly, it would be good for many l10n people if this PR is accepted.
Hey I'm sorry this has sat for so long. I'm finally getting a look at it.
Thank you again -- merged via #3882