Skip to content

Cldr Units version 3.10.0

Compare
Choose a tag to compare
@kipcole9 kipcole9 released this 26 Dec 23:27

Bug Fixes

  • Further refinement to Cldr.Unit.unit_category/1 to return a result in a broader range of cases.

Enhancements

  • Adds :only and :except options to Cldr.Unit.parse/2. These options provide a mechanism to disambiguate the unit when a unit string could refer to more than one unit. For example, "2w" could refer to either "2 weeks" or "2 watts". If neither option is provided then the result is the same as in prior releases: the unit with the lexically shorter and alphabetically earlier unit is returned.