Closed rbarkhouse closed 6 years ago
Hello @rbarkhouse,
According to the polyglot.js documentation, it seems like you have to use ${smart_count}
variable name to activate pluralization feature.
Anyway, I think some tests should be added about this features. (pluralization, interpolation).
Ack, you are very right, I didn't notice that in their docs. Thanks, and thanks for this library!
I'm trying to use the Polyglot plural syntax but it doesn't seem to be working as expected... I have the following string in my bundle:
"NumberOfNetworksReporting": "%{count} network is reporting |||| %{count} networks are reporting"
If I provide an object with interpolation values, it ends up printing the whole string with both forms, including the pipe characters:
If I use Polyglot's alternate syntax (pass a number as the second argument), it appears to be doing the proper plural phrase selection, but it doesn't substitute the actual value:
Any suggestions? Rick