| Jel.String.plural = function( | str, | | count | ) |
|
returns the plural of a given string, based on a given count. Observes a lot of the specific pluralisation rules in the English language (that is, not always just adding an s to the end of a word).
Arguments
| str | String, the word to pluralise if count != 1 |
| count | Integer, affects whether the string is pluralised or not (not pluralised if this equals 1) |
Example
Jel.String.plural("car", 2); // "cars"
Jel.String.plural("fly", 1); // "fly"
Jel.String.plural("fly", 2); // "flies"