Skip to content

Releases: nuxt-modules/i18n

v10.6.0

Choose a tag to compare

@github-actions github-actions released this 30 Jul 10:49

This release is mostly about performance, and about making the domain features behave consistently.

Faster builds and faster SSR

Locale messages are no longer bundled into your server build as JavaScript, no longer shipped as client chunks when they are served from the messages endpoint, and no longer copied on every server-rendered request.

Building a Nuxt app with 10 locales of around 2,000 messages each and 10 pages:

10.5.0 10.6.0
build time 9.2s 5.7s 38% faster
peak build memory 3.6 GB 2.5 GB 30% less
build output added by the module 12.9 MB 3.2 MB 75% smaller
SSR throughput 785 req/s 1722 req/s 2.2× higher

Median of three runs on an M4 Pro with Nuxt 4.5; throughput over 10 concurrent connections. The same app without the module builds in 3.4s and outputs 3.2 MB.

How much of this you notice depends on how many messages your app loads: a few locales with a few hundred messages each will barely differ, larger message sets gain the most. It covers messages the module can read while building — .json, .yaml and .json5 files. Locale files written as .ts or .js produce their messages at runtime, so both their build and their SSR cost stay as they were. Apps that previously ran out of memory building large message sets should now complete.

This should work without any changes on your side. The new message handling can be turned off with experimental.optimizeMessageBundling: false if you run into trouble — and if you do, please let us know so we can sort it out.

Domains

differentDomains and multiDomainLocales now agree on which locale each domain serves, which URL a locale is advertised on, and where a visitor goes when the locale they asked for lives on another domain. hreflang and canonical links name one domain per locale, so every domain in your setup describes the same set of pages instead of each claiming the languages for itself.

10.5.0 could also stop serving a locale at its own domain root, redirecting / to the prefixed path and returning 404 for unprefixed paths. A domain that serves exactly one locale is treated as that locale's default again, so domainDefault is not needed for it.

Changelog

   🚀 Features

   🐞 Bug Fixes

   🏎 Performance

    View changes on GitHub

v10.5.0

Choose a tag to compare

@github-actions github-actions released this 21 Jul 14:05

✨ Custom paths via definePageMeta() in all modes

Custom paths set with definePageMeta() are now used in all customRoutes modes instead of only in 'meta' mode. If a route has custom paths from multiple sources the definePageMeta() value takes precedence and a warning is logged during build, this makes it possible to migrate from the pages option or the deprecated defineI18nRoute() macro one page at a time.

Route meta is now the canonical source of custom paths at build time, this allows projects and modules to set custom paths on routes they add or change in the pages:extend hook, see Hooks and modules.

🛠️ Under the hood

The logic behind differentDomains and multiDomainLocales now shares a single implementation, we're exploring whether these can be combined under a single config option in v11.

Please try it out and let me know if you run into any issues 🙏


   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub

v10.4.1

Choose a tag to compare

@github-actions github-actions released this 10 Jul 16:21

   🐞 Bug Fixes

    View changes on GitHub

v10.4.0

Choose a tag to compare

@github-actions github-actions released this 21 May 13:43

   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub

v10.3.0

Choose a tag to compare

@github-actions github-actions released this 24 Apr 14:20

   🚀 Features

  • Experimental regex routes  -  by @BobbieGoede in #3957 (07a9b)
    • consolidates per-locale route duplication into regex-based routes, significantly reducing the route count in apps with many locales. Opt-in via experimental.compactRoutes: true.

   🐞 Bug Fixes

    View changes on GitHub

v10.2.4

Choose a tag to compare

@github-actions github-actions released this 23 Mar 21:48

   🐞 Bug Fixes

    View changes on GitHub

v10.2.3

Choose a tag to compare

@github-actions github-actions released this 06 Feb 16:39

No significant changes

    View changes on GitHub

v10.2.2

Choose a tag to compare

@github-actions github-actions released this 06 Feb 15:38

   🐞 Bug Fixes

    View changes on GitHub

v10.2.1

Choose a tag to compare

@github-actions github-actions released this 17 Nov 11:31

   🐞 Bug Fixes

   🏎 Performance

    View changes on GitHub

v10.2.0

Choose a tag to compare

@github-actions github-actions released this 02 Nov 10:19

   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub