@nuxt/core
2.18.1 · 28 Jun 2024MIT164.6k / weekRepositoryHomepagenpmAtom feed
2.18.1 is the newest release of 2.x.
In short
2 deprecated20 new2 fixed10 changed
- Deprecated
Deprecate
styleResourcesbecause of performance issues. Use our new community module instead (it's a drop-in replacement) - Deprecated
Deprecate callback-based
asyncData,fetchandmiddlewaremethods. Use Promises or async/wait instead.
Release note
Release Notes
With v2.3, Nuxt.js is splitted into smaller packages (Aka a mono-repo). This means smaller packages, independent versioning support and ability to replace any part of Nuxt.js without dirty hacks. Before this release, we carefully tested the latest updates using edge release channel against real-world projects and there should be no breaking changes.
Please note that for upgrading Nuxt.js just changing version inside package.json is not enough. Please use yarn upgrade or npm upgrade so that the final directory structure of node_modules will be correct. In case of problems clean up node_modules and yarn.lock/package-lock.json. Still having problems? open an issue in cmty!
Fixes and Enhancements
CLI and DX improvements
CLI cleanups and improvements
Improve nuxt-loading component
Set defaults for port and host values
Dynamically read environment variables when loading
nuxt.config.js(PR #4208)Support custom pushAssets function to control http2 push headers
Reduce duplicate code in
routes.jsPrint warning when using
build.extractCSS.allChunksThrow an error when layout property is not string
Use
require.resolveto get the path of babel-loaderCheck style resources for existence
Serialize config head fn shorthand correctly
Don't accept ranges
Correctly resolve layouts with nested custom dir
Warn on unknown mode
Use
postcss.orderto change order of postcss pluginsFix for double escaping static class on SSR
Fix stable route sorting for Node v11
New Features
Dedicated help command (
nuxt help [cmd])List commands
nuxt --helpSupport asynchronous
nuxt.config.js
Dependency Upgrades
Deprecations
- Deprecated
Deprecate
styleResourcesbecause of performance issues. Use our new community module instead (it's a drop-in replacement) - Deprecated
Deprecate callback-based
asyncData,fetchandmiddlewaremethods. Use Promises or async/wait instead.
Internal Refactors
Migrate nuxt into a mono-repo
Refactor core into
@nuxt/core,@nuxt/serverand@nuxt/vue-rendererRefactor builder into
@nuxt/builderand@nuxt/webpackMove
@nuxtjs/babel-preset-appinto nuxt mono-repo and republish it as@nuxt/babel-preset-appMove common config to
@nuxt/configPackaging and development improvements
Extract
eslint-configinto own packageSeveral test utils cleanups (PR #4180)
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.