Nitro v2.10 release had been delayed due to major (non-breaking) structure changes making sure Nitro 2.x is forward-compatible until community adoption happens. It might be delayed a little bit longer mainly to have enough time to make sure there are no regressions and well-test ecosystem compatibility.
⭐ Highlights
You can use nitro instead of nitropack for imports and dependency (#2497)
Nitro structure and presets is revamped with new structure and subpath exports (#2473, #2446)
Nitro now uses compatibility dates to allow leveraging the latest platform features without major versions (#2511)
✅ Migration
Although migrating to Nitro v2.10 from older 2.x versions is not mandatory, it is highly recommended that you migrate:
Runtime imports
If you were previously importing from #internal/nitro/* or nitropack/runtime/* you should change them to #imports or nitropack/runtime.
--- import { defineNitroPlugin } from "#internal/nitro/plugin"
--- import { defineNitroPlugin } from "nitropack/runtime/plugin"
+++ import { defineNitroPlugin } from "#imports"
+++ import { defineNitroPlugin } from "nitropack/runtime"
Compatibility date
Adding compatibility date, make sure you can leverage from latest platform enhancements. If this config is not provided nitro will keep using v2.9 behavior for presets. Nitro will show a guide about adding it and if you are using nitro dev command it can automatically add it.
Nitro has a nightly release channel that automatically releases for every commit to try the latest changes. You can opt-in by updating your package.json:
Nitro v2.10 release had been delayed due to major (non-breaking) structure changes making sure Nitro 2.x is forward-compatible until community adoption happens. It might be delayed a little bit longer mainly to have enough time to make sure there are no regressions and well-test ecosystem compatibility.
⭐ Highlights
nitro
instead ofnitropack
for imports and dependency (#2497)✅ Migration
Although migrating to Nitro v2.10 from older 2.x versions is not mandatory, it is highly recommended that you migrate:
Runtime imports
If you were previously importing from
#internal/nitro/*
ornitropack/runtime/*
you should change them to#imports
ornitropack/runtime
.Compatibility date
Adding compatibility date, make sure you can leverage from latest platform enhancements. If this config is not provided nitro will keep using v2.9 behavior for presets. Nitro will show a guide about adding it and if you are using
nitro dev
command it can automatically add it.🌃 Try via the nightly channel
Nitro has a nightly release channel that automatically releases for every commit to try the latest changes. You can opt-in by updating your
package.json
:(for nuxt users)
🚀 Enhancements
ignore
option (#2302)🩹 Fixes
💅 Refactors
📖 Documentation