• Overview
@angular/common

getLocaleCurrencyCode

function
deprecatedsince v4217

Retrieves the default currency code for the given locale.

Deprecation warning

We recommend you create a map of locale to ISO 4217 currency codes. Time relative currency data is provided by the CLDR project. See https://www.unicode.org/cldr/charts/44/supplemental/detailed_territory_currency_information.html

API

function getLocaleCurrencyCode(locale: string): string | null;

Description

Retrieves the default currency code for the given locale.

The default is defined as the first currency which is still in use.

Jump to details