Historial

Qué hay de nuevo en astro-intl

Un registro detallado de cada feature, fix y cambio importante en todas las versiones.

1.0.3

latest
Cambiado

createIntlMiddleware() now automatically sets locales and defaultLocale in the intl store via __setIntlConfig. Users who use middleware no longer need to pass these options to intl() in astro.config.mjs.

Agregado

defaultLocale option in IntlMiddlewareOptions type.

1.0.2

initial
Agregado

Configurable defaultLocale option — no more hardcoded "en" fallback.

Agregado

runWithLocale() — concurrency-safe request context via AsyncLocalStorage.

Agregado

Multi-runtime support — auto-detects AsyncLocalStorage (Node.js) with global-variable fallback (Cloudflare Workers, Deno).

Agregado

IntlConfig type exported for integration configuration.

Cambiado

Modular architecture — core.ts split into sanitize, interpolation, store, translations modules.

Cambiado

react.ts now imports shared escapeRegExp from sanitize.ts (removed duplicate).

Corregido

Race condition in SSR — concurrent requests no longer share state.

Corregido

Hardcoded "en" fallback locale now respects defaultLocale config.

1.0.1

initial
Agregado

Variable interpolation with t("key", { name: "value" }).

Agregado

t.markup() for HTML in translations with security sanitisation.

Agregado

t.rich() for React with nested tag support.

Agregado

defineRequestConfig() for global config registration (next-intl style).

Agregado

Messages via integration options (messages config).

Agregado

BCP-47 locale validation.

Agregado

Prototype-pollution protection in dot-path traversal.

Agregado

HTML sanitisation (defence-in-depth) in t.markup().

1.0.0

initial
Agregado

Initial release.

Agregado

setRequestLocale() for URL-based locale detection.

Agregado

getLocale() to read current locale.

Agregado

getTranslations() with namespace support.

Agregado

getTranslationsReact() for React components.

Agregado

Type-safety with DotPaths.

Agregado

Native Astro integration.