Releases: robisim74/angular-l10n
Releases · robisim74/angular-l10n
v16.0.0
Features
-
Angular version: ^16.0.0
-
Add
provideL10n*
functions to support standalone apps
BREAKING CHANGES
- Change
L10nResolve
toresolveL10n
function for lazy loading - Change
L10nUserLanguage
toL10nLocaleResolver
- Remove
L10nRoutingModule
: create a localized routing
v15.0.0
v14.0.0
Features
-
Angular version: ^14.0.0
-
Add
l10nPlural
&l10nDisplayNames
directives -
l10nPlural
pipe & directive now pass the value as parameter to translation
BREAKING CHANGES
l10nDateAsync
&l10nNumberAsync
have a different signature:language
parameter was moved to the end
Notes
- To use pipes & directives in standalone components (in dev preview), you have to import
L10nTranslationModule
orL10nIntlModule
(depending on the pipes and directives you need). When standalone components will be stable, also pipe & directives of this library will be standalone, and you will be able to import them individually as well as through ng modules.
v13.1.0
v13.0.0
Features
- Angular version: ^13.0.0
- Now that angular has removed IE support, Intl is fully supported and you should no longer need polyfills
APP_INITIALIZER
is now included inforRoot
ofL10nTranslationModule
- Add Unit identifiers in
L10nLocale
- Add optional convert function as parameter to
l10nNumber
pipe and directive - Directives now support strictTemplate
BREAKING CHANGES
- Make sure to have in your
tsconfig
:
"lib": [
"es2020",
"dom"
]
- You can remove
initL10n
from providers inAppModule
:
// No longer needed
providers: [
{
provide: APP_INITIALIZER,
useFactory: initL10n,
deps: [L10nLoader],
multi: true
}
],
- If you are calling
loadTranslation
passing new providers, now you need to add them to the configuration first:
const i18nLazyAsset = { 'en-US': {...}, 'it-IT': {...} };
this.translation.addProviders([{ name: 'lazy', asset: i18nLazyAsset}]);
this.translation.loadTranslation([{ name: 'lazy', asset: i18nLazyAsset}]);
v12.0.1
v12.0.0
v11.1.0
v11.0.0
Features
- Angular version: ^11.0.0
- Add
l10nPlural
pipe - Add Intl DisplayNames &
l10nDisplayNames
pipe
BUG FIXES
- Add support to TrustedHTML when innerHTML is used
BREAKING CHANGES
- New signature for
plural
method ofL10nIntlService
: now support a key prefix parameter - New signature for
getBrowserLanguage
method ofutils
: now requires theL10nFormat
parameter