Core API

ICU Formatting

pico-intl implements a lightweight subset of ICU message syntax for select, selectordinal, and nested formatting.

ts
{
  "role": "{{role, select, admin{Admin} user{User} other{Guest}}}",
  "updated": "Updated {date, date, ::yMMMd}"
}

Key points

  • select and selectordinal are flat ICU-lite clauses.
  • Inline number/date/time formatting delegates to native Intl.
  • Complex nested message trees are intentionally outside core.

Next step

Copy the example into a small fixture, run the validation commands, and keep framework-specific routing, hydration, or SSR behavior covered by your app tests.