View Source Bonfire.Common.Localise.Cldr.Number.PluralRule.Range (Bonfire v0.9.10-classic-beta.169)

Implements plural rules for ranges

Summary

Functions

Returns a final plural type for a start-of-range plural type, an end-of-range plural type and a locale.

Functions

Link to this function

plural_rule(first, last, locale)

View Source

Returns a final plural type for a start-of-range plural type, an end-of-range plural type and a locale.

Arguments

  • first is a plural type for the start of a range

  • last is a plural type for the end of a range

  • locale is any Cldr.LanguageTag.t or a language name (not locale name)

Example

iex> Bonfire.Common.Localise.Cldr.Number.PluralRule.Range.plural_rule :other, :few, "ar"
:few