Optimizing regional support with improved globalization APIs
Multilingual applications use globalization to give users from different countries and backgrounds a regional experience. Angular has built-in APIs for managing both internationalization and localization. In this section, we will walk through configuration and implementation examples to illustrate some of the new globalization possibilities Ivy brings us.
Bundling localizations
Angular uses locale data for regional variations for formatting dates, currencies, decimal numbers, and percentages. In Angular Ivy, we can bundle a single locale as part of the build by using the localize
builder option. Let's say we wanted our application to use the French locale. We can do this by configuring our project build as follows. This also implicitly replaces the value provided for the LOCALE_ID
dependency injection token in the @angular/core
package:
{ "projects": { "my-app...