Skip to content

i18n IVY - Next.12 LocaleID not set #15896

@spock123

Description

@spock123

🐞 bug report

Description

Setting locale in angular.json is ignored by the compiler.
No matter the locale, injecting the localeID token gives "en-US" .

🔬 Minimal Reproduction

Set locale in angular.json

              "i18nFile": "src/locale/messages.sv.xlf",
              "i18nFormat": "xlf",
              "i18nLocale": "sv",
              "baseHref": "/sv/"

Serve the app, inject localeID token and print it out, gives "en-US"

🌍 Your Environment

Angular Version:



Angular CLI: 9.0.0-next.12
Node: 12.2.0
OS: darwin x64
Angular: 9.0.0-next.12
... animations, cli, common, compiler, compiler-cli, core, forms
... language-service, localize, platform-browser
... platform-browser-dynamic, router, service-worker

Package                            Version
------------------------------------------------------------
@angular-devkit/architect          0.900.0-next.12
@angular-devkit/build-angular      0.900.0-next.12
@angular-devkit/build-optimizer    0.900.0-next.12
@angular-devkit/build-webpack      0.900.0-next.12
@angular-devkit/core               9.0.0-next.12
@angular-devkit/schematics         9.0.0-next.12
@angular/cdk                       9.0.0-next.0
@angular/material                  9.0.0-next.0
@angular/material-moment-adapter   9.0.0-next.0
@angular/pwa                       0.900.0-next.12
@ngtools/webpack                   9.0.0-next.12
@schematics/angular                9.0.0-next.12
@schematics/update                 0.900.0-next.12
rxjs                               7.0.0-alpha.0
typescript                         3.6.4

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions