angular-ecmascript-intl
Advanced tools
Comparing version
@@ -7,6 +7,7 @@ import * as i0 from "@angular/core"; | ||
import * as i5 from "./currency/intl-currency.pipe"; | ||
import * as i6 from "./country/intl-country.pipe"; | ||
export declare class IntlModule { | ||
static ɵfac: i0.ɵɵFactoryDeclaration<IntlModule, never>; | ||
static ɵmod: i0.ɵɵNgModuleDeclaration<IntlModule, never, [typeof i1.IntlDatePipe, typeof i2.IntlLanguagePipe, typeof i3.IntlDecimalPipe, typeof i4.IntlPercentPipe, typeof i5.IntlCurrencyPipe], [typeof i1.IntlDatePipe, typeof i2.IntlLanguagePipe, typeof i3.IntlDecimalPipe, typeof i4.IntlPercentPipe, typeof i5.IntlCurrencyPipe]>; | ||
static ɵmod: i0.ɵɵNgModuleDeclaration<IntlModule, never, [typeof i1.IntlDatePipe, typeof i2.IntlLanguagePipe, typeof i3.IntlDecimalPipe, typeof i4.IntlPercentPipe, typeof i5.IntlCurrencyPipe, typeof i6.IntlCountryPipe], [typeof i1.IntlDatePipe, typeof i2.IntlLanguagePipe, typeof i3.IntlDecimalPipe, typeof i4.IntlPercentPipe, typeof i5.IntlCurrencyPipe, typeof i6.IntlCountryPipe]>; | ||
static ɵinj: i0.ɵɵInjectorDeclaration<IntlModule>; | ||
} |
{ | ||
"name": "angular-ecmascript-intl", | ||
"version": "0.2.0", | ||
"version": "0.3.0", | ||
"peerDependencies": { | ||
@@ -5,0 +5,0 @@ "@angular/common": "^15.1.0", |
@@ -0,1 +1,3 @@ | ||
export * from './lib/country/intl-country.pipe'; | ||
export * from './lib/country/intl-country-pipe-default-options'; | ||
export * from './lib/currency/intl-currency.pipe'; | ||
@@ -2,0 +4,0 @@ export * from './lib/currency/intl-currency-pipe-default-options'; |
@@ -154,2 +154,21 @@ # Angular ECMAScript Intl | ||
### Country pipe | ||
Use the country pipe like the following: | ||
``` | ||
{{'US' | intlCountry: options}} | ||
``` | ||
The input can be one of the following: | ||
* string (must be two-letter ISO 639-1 language code or a three-letter ISO 639-2 language code) | ||
* null | ||
* undefined | ||
The options are the same as the options for `new Intl.DisplayNames()`. For a list of the options, see | ||
their [docs](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/DisplayNames/DisplayNames). | ||
With the `INTL_COUNTRY_PIPE_DEFAULT_OPTIONS` injection token you can specify default options. | ||
## Background | ||
@@ -162,3 +181,2 @@ | ||
* Performance: Prepare Intl.* object with default options, only construct new object when necessary | ||
* Country pipe | ||
* Relative time | ||
@@ -169,6 +187,3 @@ * Migration Schematics for usages of Angular pipes | ||
* Linting | ||
* Pull request verification | ||
* Automatic dependency updates | ||
* Automatic npm publishing | ||
* Automatic changelog generation |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
138280
16.4%42
10.53%1116
17.1%187
8.72%