Pluralize stands for an automate script process, that checks a word (for example, english word "box") and adds its plural end "es", so it comes "boxes", when it is needed to be plural. Term is used in many programming languages.
Questions tagged [pluralize]
146 questions
1
vote
1 answer
Rails 3 and Slovenian pluralization
I'd like to use t('errors', :count => 2) with slovenian translation in Rails 3.0.9 and want it to return "2 napaki" which is a special plural form for slovene language.
I have created locales/sl.yml and have this code:
sl:
error:
one: %{count}…

pr0factor87
- 13
- 2
1
vote
2 answers
Rails 2.3.9 pluralize model names issue
I'm developing a simple select. The thing is my code needs to be in spanish, so
instead of using Role I have to use Rol (the plurar remains the same: Roles).
So, my model name is: Rol and my Controller name: Roles and in my DB: Roles
<% roles =…

tiiin4
- 539
- 4
- 7
- 19
1
vote
1 answer
React-Intl plural message getting errors
The message is Check out {count, plural, one {# item}, other {# items}}.
I'm invoking it with:
But I'm getting these errors:
[React Intl] Error formatting message:…

NotoriousWebmaster
- 3,298
- 7
- 37
- 49
1
vote
4 answers
Making a value plural (Greater than, Less than) in Javascript
I have the following code:
$(function(){
var total_click = 0;
$("#mapKey a.showKey").click(function(){
total_click = total_click + 1;
$("#counter").text("I cheated " + total_click + " whole" +…

Yahreen
- 179
- 2
- 10
1
vote
0 answers
Plural values are deleted by i18next-scanner
Recently I came across a strange behavior, I am not sure whether is my fault or a bug ... (probably my fault though)
I have the following Trans Component:
…

Raffaele Tosti
- 11
- 1
1
vote
2 answers
Rails pluralize count when zero, does not work with number_with_delimiter method
I am trying to make a pluralization work with zero case and also using number_with_delimiter to make it readable with bigger numbers.
So, I have in my YAML file:
count:
zero: no counts
one: 1 count
other %{count} counts
And in the view:
t…

pzin
- 4,200
- 2
- 28
- 49
1
vote
0 answers
angular-l10n pluralization with ICU messageformat
We are testing with the angular-l10n package to implement localization in our angular 7 project. We have run into some challenges with plural translations. We are trying to port over some Spanish translations being used in our angular JS…
1
vote
2 answers
Trying to understand Golang pluralization
I'm trying to understand pluralization in Go. The example from the docs https://godoc.org/golang.org/x/text/message/catalog#hdr-String_interpolation does not work. The method plural.Select does not event exist. It should be plural.Selectf. Note the…

zemirco
- 16,171
- 8
- 62
- 96
1
vote
0 answers
How to do active record associations with non-plural table names?
I'm trying to get an active record association working for two tables that do not have a plural form but still can imply multiple ( Equipment and JobEquipment)
I keep getting the following error when I try and get the Equipment from a the…

SegFaultDev
- 455
- 1
- 7
- 24
1
vote
1 answer
Pluralization issues within spring boot project
Currently I'm using Spring-boot + Thymeleaf and multiple languages. I can't find any easy way to use ICU4j with these. Essentially, as I get it, all what is need is to replace ResourceBundleMessageSource and its MessageFormat with the ICU4J…

arctica
- 336
- 4
- 14
1
vote
2 answers
Why does Rails use plurals for new and create?
I understand why a Rails index method would use the plural form of a resource - we're showing all projects, for example.
And I understand why the show method would use the singular form - we only want to see one project, with a particular ID.
But I…

Nathan Long
- 122,748
- 97
- 336
- 451
1
vote
0 answers
How to deal with non-integers and Symfony's transchoice
According to the documentation, the $number argument of TranslatorInterface::transChoice expects an integer. This is great for things like number of comments and such, but what about non-integers?
Say I want to pluralize an amount of years. My…

user2323470
- 183
- 9
1
vote
1 answer
How to get accurate pluralization with Rails pluralization
I need very accurate pluralization for my application
I am currently using the Rails built in pluralization method.
I found a problem with the word 'foot'.
When I do:
"foot".pluralize(2)
=> "foots"
The correct pluralization should be feet.
How can…

chell
- 7,646
- 16
- 74
- 140
1
vote
1 answer
ng-pluralize hide element when value is 0 (zero)
I would like to user Angulars ng-pluralize to hide/show/change an element in such way that of the value is 0, the element should be hidden (as in ng-hide="value == 0" or ng-if="value != 0").
When the value is 1, the element should have one text, and…

BluePrint
- 1,926
- 4
- 28
- 49
1
vote
1 answer
Yii2 REST api pluralize is not working
I have been setting up REST on Yii2 for two days already, and due to different issues and lack of details in documentation I haven't reach my goals yet.
For now I need to make pluralize working for my controller. I can get all users by requesting…

Bandydan
- 623
- 1
- 8
- 24