Why Parla
A missing key, a missing param, a namespace read before it loads: each renders a blank, and TypeScript could catch each. Parla makes the types match what runs.
The name
Section titled “The name”Parla, pronounced /ˈparla/ (“PAR-lah”), is Italian for “speaks” (and “speak!”), from the verb parlare, “to speak”.
The reasons
Section titled “The reasons”tis proof of loading. It holds only the namespaces sure to be loaded; reading another is a type error. Namespaces are imports, so types and bundle follow the same imports.- Params come from the message: a plural’s number, a select’s params per branch, a callback per rich-text tag.
- One way to call each thing.
loadanduseParlaalways take a list, so tooling such as x18n reads one shape. - No flash on switch.
switchLocaleloads first, then switches. - ICU and MessageFormat 2, per namespace.
- No locale data to ship. Formatting uses
Intl. - Monorepos. One package owns each namespace; apps import it.
What each library has and lacks
Section titled “What each library has and lacks”From each library’s docs and parla-benchmark.
| Parla | i18next | react-intl | Lingui | Paraglide | typesafe-i18n | |
|---|---|---|---|---|---|---|
| Typed keys | Yes | Opt-in, CustomTypeOptions |
Opt-in, augmented ids |
Opt-in, augmented Register |
Yes, generated functions | Yes, generated |
| Typed params | Yes, from the message; selects per branch | Inferred from as const resources, ~90k type instantiations, 53–86k with the selector API |
Opt-in, per ID; declared, not read from the message | No: Record<string, unknown> |
Names | Yes |
| Typed loading | t has only loaded namespaces |
No: suspends, or a ready flag |
No | No | No loading: messages are imports | No: empty string before load |
| Lazy chunks | Per locale × namespace, built in | Backends, wired by the app | Not documented | Per locale, app code | Every locale per message; per-locale builds experimental | Per locale, generated |
| Syntax | ICU and MF2, per namespace | Own; ICU and MF2 via plugins | ICU | ICU | inlang’s, MF2-inspired; ICU via plugin | Own |
| Rich text | Each tag a typed callback; node type follows the instance | <Trans>; tag typing not documented |
Value functions; typed by opt-in generics | Components; tag typing not documented | Markup names type-checked (React adapter) | Not built in |
| Monorepos | One owner package per namespace, imported | Per-package namespace types | Libraries take the app’s intl |
Catalog per app, or merged | Shared project, each package compiles | Not documented |
| Runtime, gzip | 3.2 kB with React | 17.6 kB with react-i18next | 6.8 kB, precompiled | 4.1 kB | 1.6 kB per-locale build, no React binding | 1.6 kB |
| Switching locale | Loads first, then switches; never suspends | Suspends while loading | Recreate the intl object |
App code: load, then activate | Reloads the page by default | Not documented |
Sizes exclude React; see parla-benchmark.
Each library gets part of this right; of those in the table, only Parla types keys, params and loading at once. Not in it: next-intl types keys and params, both opt-in, for Next.js; Intlayer declares content in typed files. No idea here is new: the launch post credits each.
Parla is built with the help of AI coding tools.