Releases: nuxt-modules/i18n
v9.2.0
⚙️ Opt-in alternate link consistency
You can now opt into a new experimental option experimental.alternateLinkCanonicalQueries
, this will remove non canonical query parameters from the alternate links returned by useLocaleHead
. Based on the discussions in #3296, check out the option documentation here.
🚀 Features
- Opt-in alternate link consistency - by @divine and @BobbieGoede in #3320 (16d8e)
🐞 Bug Fixes
availableLocales
not including configured locales - by @BobbieGoede in #3347 (1647b)- Load fallback messages on first access - by @BobbieGoede in #3352 (c79ff)
View changes on GitHub
v9.1.5
🐞 Bug Fixes
- I18n locale and config macro undefined on server-side - by @BobbieGoede in #3337 (88a29)
View changes on GitHub
v9.1.4
🐞 Bug Fixes
- Regression detect and set locale using initial route server-side - by @BobbieGoede in #3334 (d5796)
View changes on GitHub
v9.1.3
🐞 Bug Fixes
- Locale switching middleware in static build - by @BobbieGoede in #3323 (21fcf)
- Check if resolved localized route name exists - by @BobbieGoede in #3325 (8b42e)
- Consistent composer instance properties across scopes - by @BobbieGoede in #3324 (ab6e5)
View changes on GitHub
v9.1.2
🐞 Bug Fixes
- Hook timing and separate i18n plugin - by @BobbieGoede in #3266 (fbdc3)
- Improve options template types - by @BobbieGoede in #3279 (12621)
- Refactor and improve localized route resolution - by @BobbieGoede in #3283 (df494)
- Custom paths
pages
config should use route name as key - by @BobbieGoede in #3286 (3ba77)
View changes on GitHub
v9.1.1
🚀 Features
- Configurable
bundle.optimizeTranslationDirective
- by @BobbieGoede in #3256 (1b457)
🐞 Bug Fixes
- Default language multi domain locales - by @DotwoodMedia and Vincent de Vreede in #3250 (7f7ea)
View changes on GitHub
v9.1.0
This release contains bug fixes and a new experimental option, you may need to refresh your lockfiles while updating.
⚙️ Configurable generated file and directory paths
In v9 (and lower) the i18n file and directory paths are absolute by default which could expose sensitive path information about your build environment in production.
To combat this we have added a new experimental option, experimental.generatedLocaleFilePathFormat
, which is used to configure the way these paths are processed. We will explore more approaches to improve this functionality in the future.
Check out the documentation on its usage here.
🚀 Features
- Configurable generated file and directory paths - by @BobbieGoede in #3235 (abc3d)
🐞 Bug Fixes
- Sync route parsing utilities - by @BobbieGoede in #3211 (5363e)
- Support special characters in generated messages type keys - by @BobbieGoede in #3223 (543e4)
- Messages type generation not watching locale files - by @BobbieGoede in #3224 (c0532)
- types:
View changes on GitHub
v9.0.0
We're happy to announce the stable release of v9!
The primary focus of this major release is to remove deprecated functionality and upgrade Vue I18n to v10, we did manage to sneak in some enhancements listed below.
🚨 Breaking changes
This update includes breaking changes so please make sure to review these in the migration documentation, if you run into problems during migration please open an issue so we can improve the guide!
📂 Directory restructure
We now use a default directory structure that is consistent with directory structure changes in Nuxt 4.
Here is an example of a project structure after this change:
app/
server/
i18n/
locales/
en.json
ja.json
i18n.config.ts
localeDetector.ts
nuxt.config.ts
This can be configured with the restructureDir
option which is set to i18n
by default, see the docs for more details.
🛣️ Route type generation
Code_2024-09-27_12-02-50.mp4
Experimental route type generation improves DX for all route utilities and components by adding autocompletion and stricter type checks.
This feature can be enabled with the experimental.typedPages
option, see the docs for more details.
⌨️ Messages and vue-i18n type generation
Code_2024-07-17_14-54-20.mp4
Experimental messages and vue-i18n options type generation improves DX by adding autocompletion and type safety for translation functions and configuration.
This feature can be enabled with the experimental.typedOptionsAndMessages
option, see the docs for more details.
View changes on GitHub
v8.5.6
🐞 Bug Fixes
- Custom routes not analyzed in layer with custom
srcDir
- by @BobbieGoede in #3133 (10c02) - Update intlify dependencies - by @BobbieGoede in #3137 (3bcda)
View changes on GitHub
v9.0.0-rc.2
Please take time to view the Breaking changes in v9 page for an overview of changes and migration steps required. Share your feedback and experience so we can land v9 as stable and as soon as possible 🙏
You may need to refresh lockfiles before installing to ensure the correct subdependencies are installed.
At stable release we will include a proper overview of the improvements we have made in this major version.
🚀 Features
- Experimental
vue-i18n
and messages type generation - by @BobbieGoede in #3151 (4f734)
🐞 Bug Fixes
vueI18n
resolution not usingrestructureDir
defaults - by @BobbieGoede in #3159 (a0164)- Update
@intlify/h3
dependency - by @BobbieGoede in #3165 (893f9)