Skip to content

Releases: nuxt/nuxt

v3.3.1

14 Mar 13:31
Compare
Choose a tag to compare

3.3.0 is a minor (feature) release with lots of new features to play with. 3.3.1 was a swiftly following release to patch an issue with nuxi on Windows.

πŸ‘€ Highlights

✨ Local module development DX

We've landed a raft of changes to enable local modules and improve DX. We now auto-scan your ~/modules folder and register top level files there as modules in your project (#19394). When these files are changed, we'll automatically restart the nuxt server.

  export default defineNuxtConfig({
    modules: [
      '@nuxtjs/tailwindcss',
-     '~/modules/purge-comments'
    ]
  })

We also now expose nuxt/kit for easy access to kit composables in your local project without having to install @nuxt/kit (#19422).

♻️ Restarting Nuxt

You can add files to the watch array to automatically restart the server (#19530). This is likely to be particularly useful for module authors. You can also trigger a restart of the Nuxt server with the new restart hook (#19084). We also landed a couple of fixes on restarting the Nuxt server which should improve your experience when developing.

πŸ”₯ Performance improvements

We've increased static asset maxAge to 1yr as a matter of best practice (#19335), and support tree-shaking more of your build (#19508). We also now support preloading <NuxtLink>s with a route in object-syntax (#19120).

CleanShot 2023-03-14 at 12 19 50

We also track how long it takes each module you use to perform its setup, and warn if it takes too long. You can see all these values by running your dev server with DEBUG=1

You can also opt-in to some of Nuxt's internal optimisations by configuring composables to be treeshaken in a particular environment (#19383), or to have magic keys automatically injected (#19490) - primarily useful for module authors.

πŸ› Error handling

We now handle chunk errors by default (#19086), meaning if your site updates with a redeploy, we automatically handle reloading it on navigation. You can disable this and handle it yourself with the new reloadNuxtApp composable. You can also set experimental.restoreState to preserve some of your app state across reloads.

We also have a new experimental error handling component: <NuxtClientFallback> (nuxt/framework#8216) which can capture errors rendering on server, replace them with fallback content, and granularly trigger rerendering the part with an error on the client. This can be enabled with experimental.clientFallback - feedback very welcome!

⚑️ Head improvements

We've migrated to use unhead directly (#19519) - and automatically tree-shake server-only head composables like useServerHead from your client build (#19576), meaning you can have great SEO without needing to include meta tag logic that's relevant only for crawlers in your client build.

There's also a new useHeadSafe composable that handles santising untrusted user input (#19548).

πŸͺ΅ Better logging in browser DevTools

Working with the Chrome DevTools team, we've landed a couple of features across the unjs + Nuxt ecosystem meaning we now have first-class support for hiding Nuxt internal stack traces from logs in your (Chromium-based, for now) browser (#19243). We also landed a couple of improvements with stacktraces involving Nuxt hooks (unjs/hookable#69 and unjs/hookable#68) implementing console.createTask.

Before After
CleanShot 2023-03-14 at 11 55 00 CleanShot 2023-03-14 at 11 52 27

πŸ’ͺ Type improvements

Types for server API routes are now more correct - with non-serialisable types stripped out of the return type (unjs/nitro#1002).

We also now type more of NuxtApp and correctly type unknown injections for greater type-safety (#19643).

CleanShot 2023-03-14 at 11 59 58

And if you were struggling with correct types when using transform + default with Nuxt data fetching composables, fear no more - we now infer the types correctly (#19487).

βš—οΈ Nitro enhancements

This release comes with Nitro v2.3, which brings lots of improvements of its own. Check out the release for more info.

We now support useAppConfig in nitro server routes (#19489) - a long-awaited change. Now useAppConfig is consistently available throughout your app for non-runtime configuration from layers, modules, etc.

We've also added a nitro:build:public-assets hook to allow modifying assets output from nitro's prerender/build phase (#19638).

πŸ› οΈ Build changes

As part of moving towards first-class support for PNP and pnpm support without --shamefully-hoist, we've dropped support for some internal (deprecated) utilities using CJS resolve patterns (#19537, #19608). We also now resolve dependencies like nuxt, @nuxt/kit and more using ESM search-paths. We'll be keeping a close eye on this.

We're also preparing the groundwork for support of new TypeScript Node16 module resolution (#19606), and as part of this have changed the format of our runtime output (using .js instead of .mjs extensions, providing types fields for subpath exports, and more).

πŸ—ΊοΈ Custom config schema (advanced)

We've been testing out an experimental feature to allow modules and users to extend the Nuxt config schema (#15592), and we've now enabled this by default (#19172). We expect this will be particularly useful for module and layer/theme authors, and should result in some nicer DX for their users.

Changelog

compare changes

πŸš€ Enhancements

  • nuxi: Enforce consistent casing in filenames (#19088)
  • nuxi: Reload nuxt when restart hook is called (#19084)
  • nuxt: Scan composables with star export (#19249)
  • nuxt: Add versions to runtime nuxtApp (#19064)
  • vite: Add node_modules and buildDir to x_google_ignoreList (#19243)
  • nuxi: Cli wrapper for self restart (#18641)
  • schema: Allow adding page routes without a matching file (#19173)
  • nuxt: Add support for nuxt/kit subpath for local use (#19422)
  • nuxt: Auto-register modules in ~/modules (#19394)
  • nuxt: Enable config schema by default (#19172)
  • kit,nuxt: Add component priority to allow overriding (#19252)
  • nuxt: Enable preloading object-syntax routes (#19120)
  • nuxt: Support trailingSlashBehavior in defineNuxtLink (#19458)
  • nuxt: Allow configuring treeshakeable composables (#19383)
  • nuxi,schema: Add support for setting nuxt logLevel (#19369)
  • nuxt: Support custom keyed composables (#19490)
  • nuxi: Programmatically pass nuxt config overrides (to dev) (#19371)
  • vite: Use custom logger to show vite logs (#19523)
  • nuxt: Enable chunk error handling by default (#19086)
  • nuxt: Add <NuxtClientFallback> component (#8216)
  • nuxt: Add watch option and refactor dev server restarting (#19530)
  • nuxt: Add useHeadSafe and remove layer around head imports (#19548)
  • kit, schema: Measure module setup timings (#18648)
  • nuxt: Support app config for server routes (#19489)
  • nuxt: Add nitro:build:public-assets hook (#19638)

πŸ”₯ Performance

  • nuxt: Increase static asset maxAge to 1yr (#19335)
  • vite: Mark more core functions as side-effect free ([#19508](http...
Read more

v2.16.2

01 Mar 13:06
ca8b375
Compare
Choose a tag to compare

2.16.2 is a patch release with bug fixes.

✨ Highlights

The main change in this patch release is that we now patch the crypto node built-in during build to allow Nuxt 2 to be used on Node versions greater than Node 16, which should ease the pressure users feel after Node 16 reaches its own EOL this year.

Warning
This should not be taken for an endorsement of continuing to run with Webpack 4, which is out of date and has a number of dependencies with issues. I expect that number to continue to grow, and we will not be able to resolve all of them. I would strongly urge migrating to Nuxt 3 if possible and the team will do our best to make this possible over the course of the year ❀️

πŸ‘‰ Changelog

compare changes

πŸš€ Enhancements

  • types: Add basic types for Nuxt interface (#9772)

🩹 Fixes

  • vue-renderer: Insert charset before title (#18998)
  • types: Remove non-existent properties from context (#19021)
  • Add minimum node 14.18 version constraint (#19112)
  • config: Upgrade md4 -> md5 on node > 16 (#19108)
  • vue-app: Handle promise rejection from asyncData (#18585)

🏑 Chore

❀️ Contributors

v3.2.3

28 Feb 11:23
021ba43
Compare
Choose a tag to compare

3.2.3 is a patch release with bug fixes and performance improvements.

πŸ‘‰ Changelog

compare changes

πŸ”₯ Performance

  • nuxt: Don't update manifest in dev mode (#19315)

🩹 Fixes

  • cli: Restart nuxt when distDir is unlinked (#19131)
  • vite: Normalize path emitted by vite watcher (#19179)
  • nuxt: Prefetch object-syntax routes with <NuxtLink> (#19144)
  • webpack: Use default export from webpack (#19166)
  • nuxt: Preserve (re)named imports in meta (#19192)
  • nuxt: Log errors thrown when booting the nuxt app (#19187)
  • nuxt: Preserve explicit rel attribute on internal link (#19309)
  • nuxt: Compatible route object for custom external routes (#19261)
  • vite: Handle non-iterable noExternal option (#19256)

πŸ“– Documentation

  • Fix components path (#19163)
  • pages: Add example of limiting scanned routes (#19181)
  • Update link (#19197)
  • Clarify that app config is not available (yet) in nitro (#19200)
  • Improved going further modules documentation (#19219)
  • Add docs badge (3c006b33c)

🏑 Chore

πŸ€– CI

❀️ Contributors

v3.2.2

17 Feb 16:00
Compare
Choose a tag to compare

3.2.1 is a patch release with (lots of) bug fixes and performance improvements since last week's minor release.
3.2.2 was a swiftly following release to patch an issue with nuxi init

πŸ‘€ Highlights

As a patch release, there are mostly bug fixes and performance improvements in the changelog. (Nevertheless, it's always worth reading through!) But one point of note is an experimental reload strategy when chunk errors are encountered. We're hoping to finalise the API and land it in v3.3 (our next feature release) with #19086, but you can test out an experimental version with the following config:

export default defineNuxtConfig({
  experimental: {
    emitRouteChunkError: 'reload'
  }
})

With this strategy, your app will hard reload on route changes if there's a chunk error. More info at #19038.

πŸ‘‰ Changelog

compare changes

πŸš€ Enhancements

  • nuxt: Add experimental app:chunkError hook and reload strategy (#19038)

πŸ”₯ Performance

  • nuxt: Allow tree-shaking empty meta from build (#19032)
  • nuxt: Animate transform rather than width (#19073)
  • nuxt: Don't include side-effects from #components (#19008)

🩹 Fixes

  • schema: Allow type inference of arrays in runtime config (#18931)
  • nuxt: Avoid recursive import in nitro renderer (#18948)
  • nuxt: Expose nuxt/schema subpath for augmentation (#18922)
  • nitro: Ensure ssr error statusCode is a number (#19001)
  • nuxt: Prevent hyphens forming child routes & warn if dupes are detected (#18944)
  • schema: Transpile nuxt/app by default (#19009)
  • vite: Exclude nuxt/app from optimised deps (9e789c76c)
  • vite: Respect isCustomElement config for jsx transform (#19053)
  • nuxt: Use parser to treeshake client-only declarations (#18951)
  • cli: Pass through exit code from test errors (#18959)
  • nuxt: Show client error if no page matches after validate fails (#18978)
  • cli: Read devServer options from nuxt config (#19055)
  • nuxt: Validate no // in path when constructing payload url (#19085)
  • nuxt: Restore previous check on payload url (e9ff34ace)
  • nuxt: Test generated pathname (af55b9882)
  • nuxt: Respect redirects which differ only by trailing slash (#18593)
  • nuxt: Pass nuxt + workspace paths when importing builder (#19099)

πŸ’… Refactors

  • nuxt: Combine imports from same relative path (ee2f568fc)

πŸ“– Documentation

  • Add info for nuxi devtools command (#18888)
  • Update link to bridge repo (#18950)
  • Fix typos (#18976)
  • Fix typo (#18975)
  • Fix link to ESM page (#19000)
  • Fix spacing (#19018)
  • Flatten top-level project in layers example (#18967)
  • Remove reference to obsolete static property (80f73d39c)
  • Add note about nested directory order (#19061)
  • Updated public directory explanation (#18464)
  • Add information on when mw runs & how to skip (#19083)
  • Add sendRedirect usage (#19070)

πŸ“¦ Build

🏑 Chore

  • Increase node 14 minor version constraint (#19111)
  • Update nitropack and unjs dependencies (#19100)
  • Dedupe rollup (576ce9ee3)

βœ… Tests

  • Skip vnode warning on windows dev mode (71bcd9550)

πŸ€– CI

  • Run webpack/vite and dev/prod as matrices (#18905)

❀️ Contributors

v2.16.1

13 Feb 12:16
4114864
Compare
Choose a tag to compare

Nuxt 2.16.1 is a patch release with a couple of small bugfixes to last week's 2.16.0 release.

v2.16.0...v2.16.1

🩹 Fixes

  • deps: Downgrade @types packages depending on webpack 5 (#18827)
  • config: Let webpack merge postcss plugins (#18839)
  • types: Import Location from vue-router (#18908)

🏑 Chore

  • Tag 2.x releases appropriately (aba93e9)
  • Revert node types to v16 (3d034a3)
  • Remove stub type definitions (daed62a)

❀️ Contributors

v3.2.0

09 Feb 11:06
5855c1e
Compare
Choose a tag to compare

3.2.0 is the first minor release since we've started our new release schedule. We've brought it forward by a couple of weeks to include some goodies we want you to be able to play with soon.

πŸ‘€ Highlights

  • ⚑️ Nuxt DevTools

    You can opt-in to Nuxt DevTools per-project by going to the project root and running:

    npx nuxi@latest devtools enable

    Restart your Nuxt server and open your app in browser. Click the Nuxt icon on the bottom (or press Alt+D) to toggle the DevTools.

    More information in the docs!

  • ✨ Better DX for overriding runtimeConfig, including inline type helpers

  • πŸͺ„ Automatically inferred return type for useFetch and $fetch based on method.

    It'll be a type error to use the wrong method when hitting an endpoint.

    Plus, if you have multiple methods served by a single endpoint (like ~/server/api/test.get.ts and ~/server/api/test.post.ts then the response type will match the kind of response you make.

  • πŸͺ useFetch is now integrated with event.$fetch, meaning cookies and context are now passed to api requests automagically within internal requests.

  • πŸ”₯ We now treeshake client-only components out of the server build more effectively using the experimental treeshakeClientOnly feature

    This is turned on by default but if you experience any issues, you can turn this off via:

    export default defineNuxtConfig({
      experimental: {
        treeshakeClientOnly: false
      }
    })
  • πŸ› οΈ New addRouteMiddleware kit utility for module authors

  • πŸ’ͺ Nitropack v2.2 has been released

    Lots of features, including runtime proxy support using route rules, nested fetch calls, binary and raw storage operations, exposed event.context.cf (cloudflare) and built-in session support.

    For full details see release notes

Changelog

compare changes

πŸš€ Enhancements

  • kit: Add addRouteMiddleware method (#18553)
  • cli: Warn when prerendering routes with ssr: false (#18783)
  • schema: Add type hints for runtime config (#18652)
  • nuxt: Support type auto-import (#18859)
  • nuxt: Infer useFetch return based on the method (#18526)
  • cli: Add initial support for enabling/disabling devtools (#18864)
  • nuxt: Upgrade to nitropack 2.2 (#18889)

πŸ”₯ Performance

  • vite: Use stub entry in vite server build when ssr: false (#18782)

🩹 Fixes

  • nuxt: Treeshake client-only components with placeholders (#8789)
  • webpack: Client-side typechecking when ssr: false (#18828)
  • vite: Exclude styles, not all assets (#18752)
  • nuxt: Defer adding route path to preloaded record (#18862)
  • nuxt: Don't exclude pnpm layers from nitro esbuild/imports (#9952)
  • nuxt: Use parser to treeshake <ClientOnly> (#8713)
  • Reorder the types field in package.json (#18880)

πŸ’… Refactors

  • nuxt: Within nuxt app, import directly from source file (#18902)

πŸ“– Documentation

  • Remove extra word (#18750)
  • example: Fix app config link (#18760)
  • Add useError composable (#8912)
  • Clarify augmenting input/output app config (#8953)
  • Add explanation of composable lifecycle (#8116)
  • typescript: Type-checking guide (#18768)
  • schema: Add NuxtHooks interface documentation (#18756)
  • Resolve preloadRouteComponents page heading error (#18804)
  • Update to nuxt 2.16.0 in bridge installation (#18836)
  • Add link to vue hydration mismatch docs (#18842)
  • Update auto-imports for the server part (#18848)
  • Warn about slots in server components (#18854)
  • Add explanation with augmented meta for new routes (#18901)

βœ… Tests

  • Decrease vite logging during tests (5426e5609)

❀️ Contributors

v3.1.2

03 Feb 13:02
225988e
Compare
Choose a tag to compare

3.1.2 is a patch release with bug fixes (particularly focusing on performance and DX).

Changelog

compare changes

πŸ”₯ Performance

  • nuxt: Simplify generated variable names (#18629)
  • vite: Use compiled regexp for test (#18646)
  • nuxt: Cache result of importing styles module (#18734)

🩹 Fixes

  • nuxt: Provide fallback values for undefined runtime config (#18586)
  • kit: Don't use default export of defu (#18589)
  • Use named export from defu in all places (#18624)
  • nuxt: Dedupe vue-router (#18626)
  • test-utils: Prevent orphaned processes and use baseURL when loading (#18623)
  • vite: Ensure __publicAssetsURL set before loading assets (#18642)
  • kit: Avoid adding already installed modules to internal _installedModules (#18647)
  • nuxt: Make onNuxtReady safe to run on server-side (#18706)
  • vite, webpack: Omit magic keys when import of same name is detected (#18733)

πŸ“– Documentation

  • Update vue-gtag plugin example (#18528)
  • Mention virtual file system (#18546)
  • Mention head composable as alternative to useHead (#18552)
  • Use defineEventHandler() to avoid warnings (#18557)
  • Remove unnecessary JSON.stringify() (#18590)
  • Updated unreachable docus url in documentation (#18618)
  • Add link to pages documentation to routing (#18602)
  • Add comment about needing to install @types/node manually (6b2bc680b)
  • Add note about directory import (d2c00dc46)
  • Fix array syntax (f14f3815f)
  • Fix buttons width on getting started (#18643)
  • Add .env to directory structure and improve config docs (#18594)
  • Mention options api equivalent for head() (#18650)
  • Fix broken link to esm section (#18716)
  • Improve routing validate example (#18728)

🏑 Chore

βœ… Tests

  • nuxt: Exclude new internal vue assertNumber helper (aa646f065)

πŸ€– CI

  • Publish nightly nuxt-edge for nuxt v2 (dd0e2643c)
  • Fix ref for 2.x branch (21badd9f2)
  • Allow manually dispatching nightly nuxt2 build (09114125c)

❀️ Contributors

v2.16.0

03 Feb 12:53
6dc6cef
Compare
Choose a tag to compare

Nuxt 2.16.0 is the first minor release since Feb 15, 2021. The focus is mostly on releasing the latest fixes and enhancements that have been present in nuxt-edge for some time.

✨ Highlights

⚠️ Breaking changes

  • In this PR we only support Node 14+. This is mostly an issue for dependencies, which we need to keep updated for security reasons. Going forward until its own EOL, Nuxt 2 will only officially support Node versions that have not reached their EOL.

  • New postcss options format. See #9671 for full details.

  • Dependency upgrades. A number of dependencies have dropped support for earlier node versions. dotenv has changed how it parses .env files in a number of edge cases. glob now requires / instead of \ on windows machines. There may also be other changes that affect your usage, so please do upgrade with care.

  • Vue 2.7 upgrade. Although you can use Vue 2.7 with any release of Nuxt 2, 2.16.0 for the first time includes it as a dependency, which means that you may well encounter some issues associated with upgrading Vue 2.6 -> Vue 2.7.

    This may be a good time to consider using the composition API utilities provided by https://github.com/nuxt/bridge instead, which mirror Nuxt 3's more precisely than @nuxtjs/composition-api. (You can opt-in to just these utilities by disabling the other bridge modules individually.)

Changelog

compare changes

πŸš€ Enhancements

  • config: Support nuxtrc in dist directory (#9280)
  • generator: Add ignoreEnv generate option during ensureBuild(cmd) (#8955)
  • server: Allow disabling serve-static middleware (#9365)
  • types: Add asyncData return types to component instance type (#9239)
  • vue-app: context.beforeSerialize method (#9332)
  • vue-app: Pass store to createRouter (#9629)
  • Default to core-js version 3 (#9987)
  • webpack: ⚠️ Update postcss to v8 (#9671)

🩹 Fixes

  • vue-app: Respect scroll-margin-top when navigating with hash (#9187)
  • webpack: Use javascript/auto for js rule (#9180)
  • server: Unregister error event listener (#9245)
  • babel-preset-app: Respect explicit options.targets for modern preset (#9337)
  • types: Add nuxt.config alias type (#9424)
  • vue-app: Check whether route exists within nuxt app before replacing (#9431)
  • vue-renderer: Decode route path for payload.js (#9494)
  • vue-app: Don't normalise route path if it's valid (#9460)
  • vue-app: Redirect to external url replaces current history entry (#9500)
  • utils: trailingSlash causes error with dynamic nuxt-child routes (#9505)
  • types: Add onNuxtLoaded and onNuxtReady types (#9510)
  • vue-app: Re-register components construtor in HMR (#9539)
  • types: Add typing for build.stats options (#9555)
  • babel: Loose option for babel private-property-in-object (#9631)
  • vue-app: Serialize route meta to allow functions (#9634)
  • vue-app: null check for $root access (#9150)
  • generator: Allow passing builder to getGenerator (#9574)
  • generator: Throw an error when Builder is missing (#9663)
  • vue-app: Use correct $config for finding basePath (#9706)
  • vue-renderer: Ensure custom build indicator preserves some whitespace (#9705)
  • 'npm run test' fails because the last command lacks 'yarn' (#9761)
  • generator: Decode path with ufo (#9739)
  • cli: Ensure nuxt instance is closed when skipping build (3e9d7e3)
  • Nuxt-child-key in web-types.json (#9792)
  • types: Return type of $fetch (#9854)
  • deps: Update ua-parser-js to 1.x (#9979)
  • deps: Update ya-parser-js to latest 0.7.x (#9979)
  • vue-app: Call ssrContext.unsetMutationObserver only if it exists (#10132)
  • webpack: Allow files with .cjs extension to be transpiled (#10340)
  • vue-app: Preview mode fetch (#10489)
  • webpack: Resolve .wasm extension with lower priority (#10676)
  • vue-app: Clear hide timeout when calling clear() (#10086)

πŸ“¦ Build

  • Use 7 digit edge hashes (0501a42)
  • Upgrade to rollup v3 (#18686)

🌊 Types

  • Add prefetchPayloads to router options (#9715)

🏑 Chore

  • release: V2.15.6 (a53fd32)
  • pkg: Build for es2019 target (#9328)
  • types: Add types for new false option for render.static (#9372)
  • Update error tests (d4e5998)
  • test: Revert jest and babel-jest to 26 (#9377)
  • Ignore audit 1754,1755 (39f7859)
  • Fix vetur extension syntax for GitPod (#9572)
  • Ignore globby > 12 upgrade as needs native esm (e0968a3)
  • Update rollup plugins (5614399)
  • Fix code formatting (17bbb21)
  • utils: Improve stripWhitespace utility (#9668)
  • Update license year to present (#9682)
  • Add separate file with security disclosure info (#9738)
  • Update logo (#9796)
  • doc: Fix link to contribution guide (#9815)
  • test: Fix external redirect link (#9816)
  • Update funding.yml (1f85137)
  • Update lockfile (7614360)
  • Update audit list (6f73c36)
  • Update lockfile and audit (1878b26)
  • Update issue template with nuxt 3 (#9948)
  • Enable blank issues (54542c1)
  • radme: Fix browserstack and saucelabs icons (#10068)
  • Update dependencies (#10510)
  • Update repo (773d292)
  • Ignore vue and vuex major updates (bafc814)
  • Update README.md (#10831)
  • Update pull request template (0db7e7b)
  • Update issue templates (f36fb9c)
  • Rename 2.x bug template (ba966cf)
  • Move nuxt 2 report to bottom (ce7b1a9)
  • Bump ua-parser-js version (1cedad5)
  • Bump test/dev dependencies (#18672)
  • Upgrade unjs dependencies (#18670)
  • Use named export from defu (#18679)

βœ… Tests

πŸ€– CI

⚠️ Breaking Changes

  • webpack: ⚠️ Update postcss to v8 (#9671)

❀️ Contributors

v3.1.1

25 Jan 22:18
deb0837
Compare
Choose a tag to compare

3.1.1 is a bugfix release to address a problem rendering components injected by Vue or Nuxt plugins.

Update notes

There's also a Nitro upgrade to v2.1.0 released shortly after v3.1.1, so when upgrading, please either run nuxt upgrade --force or refresh your lockfile.

Changelog

compare changes

🩹 Fixes

  • nuxt: Do not override inferred type of <NuxtPage> (#18495)
  • nuxt: Don't render unknown components with placeholder (#18494)
  • vite: Ensure newly created pages do not return 404 (#18447)
  • nuxt: Async transform for inline middleware (#18460)
  • nuxt: Augment interfaces exported from vue (#18505)

πŸ“– Documentation

  • Remove useNuxtData release alert (#18488)
  • Simplify the docs directory (#18506)
  • Add info about server-components async limits (#18513)
  • Keep app.vue file name consistent (#18517)

❀️ Contributors

v3.1.0

24 Jan 16:57
c552d1b
Compare
Choose a tag to compare

3.1.0 is the first minor release after Nuxt 3.0 including bug fixes and enhancements.

πŸ’¬ Release Discussion

πŸ‘€ Highlights

  • πŸ“– Lots of improvements to the documentation and website (you can already see them in nuxt.com)
  • 🏝️ Experimental component Islands and server only components
  • ✨ New onNuxtReady, useNuxtData and useSeoMeta composables
  • οΉ› experimental config schema (for module or theme authors)
  • πŸ’ͺ Upgraded to Nitropack v2
  • ⚑️ Migrated to Vite 4 and Rollup 3.

Changelog

compare changes

πŸš€ Enhancements

  • nuxt: Experimental server component islands (#5689)
  • nuxt: Add onNuxtReady composable (#9478)
  • useNuxtData composable (#9262)
  • nuxt: Support for extending error.vue in layers (#9521)
  • vite: Upgrade to vite 4 (#9238)
  • nuxt: Deep watch useCookie ref value by default (#9664)
  • vite: Display production build stats (#9761)
  • nuxt: Server-only components (#9972)
  • imports: imports:context hook for unimport context (#9971)
  • vite: Support build.transpile as function (#7767)
  • nuxt: Prefetch middleware/layouts + await layout loading (#10155)
  • nuxt: Support server components with extracted payloads (#10113)
  • kit: Add extendRouteRules method (#9771)
  • nuxt: Allow disabling color for <NuxtLoadingIndicator> (#18432)
  • head: useSeoMeta composable (#18441)
  • Experimental config schema (#18410)

πŸ”₯ Performance

  • nuxt: Use static import of @unhead/ssr (#9826)
  • nuxt: Add tree-shaken useServerSeoMeta composable (#18476)

🩹 Fixes

  • Remove postcss.config from schema (#9181)
  • nuxt: Include missing <NuxtPage> component props (#9204)
  • nuxt: Allow layouts to receive custom props (#9395)
  • test-utils: Do not hide vitest output (#9442)
  • nuxt: useCookie with defaults should return non-null value (#9449)
  • nuxt: Defer render-blocking prefetches until after load (#9475)
  • nuxt: Speculation rules should be reactive (#9472)
  • kit: Support applying .nuxtignore within external layers (#9599)
  • nuxt: Remove deprecated req/res access (#9636)
  • nuxt: Await plugin asyncdata promises in nuxt hook (#9616)
  • schema: Add hookable dependency (#9648)
  • vite: Skip only vite transform middleware (#9602)
  • nuxt: Remove absolute paths from routes objects (#9655)
  • nuxt: Make dev-only regexp less greedy (#9679)
  • nuxt: Set is loading state for <NuxtLoadingIndicator> after throttle (#9832)
  • cli: Show an error if no value is supplied for the --template flag (#9946)
  • vite: Defer to nitro to copy public dir (#10013)
  • nuxt: Include components runtime dir in build output (#10046)
  • nuxt: Add build.transpile strings to nitro inline list (#10094)
  • nuxt: Support deep assign on empty object for app config (#10087)
  • nuxt: Don't short circuit middleware after validate function (#9180)
  • nuxt: Don't try to override computed layouts in definePageMeta (#9161)
  • nuxt: Allow overriding lower layer composables (#10017)
  • nuxt: Update class prop type for head components (#9133)
  • nuxt: Avoid injecting url helpers into globalThis (#9627)
  • nuxt: Name anonymous components in render tree (#10011)
  • vite: Add additional before skipping vite transform (#10120)
  • kit: Resolve group syntax of ignore (#15884)
  • nuxt: Use query for hashing the fetch key (#18411)
  • cli: Prevent showing stack traces while scaffolding (#9962)
  • nuxt: Provide types for modules as array (#18416)
  • vite: Don't skip loading styles in hydration phase (#18433)
  • vite: Enable css sourcemaps in dev based on sourcemap (#18446)
  • nuxt: Await async callWithNuxt calls (#18443)
  • nuxt: Let router handle internal redirects within middleware (#18445)
  • nuxt: Import onServerPrefetch (629d2c099)
  • Upgrade unimport, close #15594 (#15594)
  • Upgrade unimport (#18475)

πŸ’… Refactors

  • jobs: Remove unused asset (#9116)
  • nuxt: Fix typo in internal plugin names (#9201)
  • nuxt: Use pathe.join for layer lookup (#9540)
  • Split out type imports from value imports (#9225)
  • nuxt: Remove vue-meta for head support (#9638)
  • nuxt: Do not add all composable auto-imports to globalThis (#9630)
  • vite: Show log when client build is starting (#9759)
  • home: Sections (#9882)
  • Heros (#9886)
  • Improve internal type definitions of <NuxtLink> (#9869)

πŸ“– Documentation

  • Update to 3.0 and upgrade theme (cd2ad7108)
  • Fix paths to migration guides (#9071)
  • Fix broken paths (#9076)
  • Set nuxt stability to stable (#9075)
  • Fix broken link (24c8653b2)
  • Update redirects (f01fc1863)
  • seo: Add robots file (#9111)
  • Improve images quality (#9112)
  • Fix broken links in examples (#9119)
  • Bump website theme version to 0.1.5 (#9125)
  • Bump nuxt-website-theme to 0.1.6 (71fed589c)
  • Update vercel icon to support dark mode (a4768fd56)
  • Update website-theme version (16117060e)
  • Fix typo in commands/add (#9206)
  • Remove stable release warning regarding options api (#9186)
  • Fix typos in modules section (#9227)
  • Updated info about 404.vue (#9155)
  • External configuration table (#9189)
  • homepage: Optimize gem textures (#9234)
  • Add space betwee...
Read more