Skip to content

Support plurality rules #18

@TheChilliPL

Description

@TheChilliPL

This package should support more plurality rules. You can use plural package for that.

In some languages, it's not as easy as one or many, but there's also zero (if the language has different ending if it's exactly zero elements), few and many.

For example, Polish requires 4 pluralities: one, few, many and other:

  • 1 miesiąc (one)
  • 2 miesiące (few)
  • 5 miesięcy (many)
  • 1.5 miesiąca (other)

The plural package deals with all the hard stuff by having algorithms to check which plurality to use with a specific number (which for Polish is quite complicated: few is used for numbers ending with 2, 3, 4; unless it's between 12 and 14, etc.) so the only thing you have to do is use the package and pass the number to it and it'll come back with either zero, one, few, many or other

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions