3

Up to angular 8 I was used to use --base-href /en/ --i18n-file=src/locale/messages.en.xlf --i18n-format=xlf --i18n-locale=en for example to generate one application per language. This approach or the i18n-options are now depreciated.

In version 9 the i18n is integrated into a package (@angular/localize) and a --localize option in the build process. I tried multiple ways and the build process is now working. In the documentation there is a lot of information about the new approach, but nowhere, how to test or switch between languages within the application.

Myonara
  • 1,197
  • 1
  • 14
  • 33

1 Answers1

0

To be fair, if you have already working application, you shouldn't have moved to the new method and could have stayed with the old setting almost without change. But since you're probably want to take advantage on the new features (obviously), the official docs refers to this guide (scroll down to the end).

As for the date, the '$localize' is still undocumented so personally I stay with the old way of files hierarchy and restart the application whenever I need to change language.

Remy
  • 1,053
  • 1
  • 19
  • 25