For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt, and this page is available as Markdown at /examples/i18n.md.

Internationalization

Translatable strings with Angular's i18n attribute and $localize, plus the device locale from LynxLocale.

What it shows

  • i18n attributes — mark template text for translation, with custom IDs such as @@app.greeting and an optional meaning and description. See Internationalization.
  • $localize — marks strings in code, with named placeholders such as ${count}:count:.
  • LynxLocale — locale() is a signal with the locale the host app (Glossary) reports. Without one, it falls back to sourceLocale in angular.json. See LynxLocale.
  • provideLocale() — in app.config.ts, it sets Angular's LOCALE_ID from that locale, so pipes format for it.
  • No translations yet — the example ships no translation files, so it shows the source text.