l10n.js icon indicating copy to clipboard operation
l10n.js copied to clipboard

Can you do translations with numbers?

Open cyphix333 opened this issue 8 years ago • 2 comments

Just wondering what if you wanted to do translation on a string that has a number in it?

For example:

There (is,are) {n} cat(s)

So what it would do is find the translation string to translate the words, choose the correct term between is and are, show the locale specific number based on what number you passed in (somehow) and also display either the non-plural or plural version of the word cat.

...or is this outside this library's scope?

Thanks!

cyphix333 avatar Dec 20 '16 15:12 cyphix333

This is outside of scope for this particular library, though I may make a new more modern library (perhaps even backwards compatible with this one if people are interested) in the future. 👍

eligrey avatar Jun 07 '21 03:06 eligrey

It's been some time since I posted this, but sure, would be interested in something like that :)

cyphix333 avatar Jun 13 '21 11:06 cyphix333