Skip to content

Latest commit

History

History
31 lines (20 loc) 路 1.5 KB

i18n-common-format-data-locale.md

File metadata and controls

31 lines (20 loc) 路 1.5 KB

Format data based on locale

{@a i18n-pipes}

Angular provides the following built-in data transformation pipes. The data transformation pipes use the LOCALE_ID token to format data based on rules of each locale.

For example, {{today | date}} uses DatePipe to display the current date in the format for the locale in LOCALE_ID.

To override the value of LOCALE_ID, add the locale parameter. For example, to force the currency to use en-US no matter which language-locale you set for LOCALE_ID, use this form: {{amount | currency : 'en-US'}}.

@reviewed 2021-09-15