MyApp.Cldr.Locale.territory_from_locale

You're seeing just the function territory_from_locale, go back to MyApp.Cldr.Locale module for more information.
Link to this function

territory_from_locale(locale)

View Source (since 2.18.2)

Specs

territory_from_locale(Cldr.LanguageTag.t() | Cldr.Locale.locale_name()) ::
  Cldr.territory()

Returns the territory from a language tag or locale name.

Arguments

Returns

  • A territory code as an atom

Examples

iex> MyApp.Cldr.Locale.territory_from_locale "en-US"
:US

iex> MyApp.Cldr.Locale.territory_from_locale "en-US-u-rg-GBzzzz"
:GB