Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/app-bun/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"test": "bun test"
},
"dependencies": {
"nuxt": "^4.3.1"
"nuxt": "^4.4.2"
},
"devDependencies": {
"@nuxt/test-utils": "latest",
Expand Down
2 changes: 1 addition & 1 deletion examples/app-cucumber/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"test": "NODE_OPTIONS='--loader ts-node/esm' NODE_ENV=test cucumber-js"
},
"dependencies": {
"nuxt": "^4.3.1"
"nuxt": "^4.4.2"
},
"devDependencies": {
"@cucumber/cucumber": "12.7.0",
Expand Down
2 changes: 1 addition & 1 deletion examples/app-jest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"test": "node --no-warnings --experimental-vm-modules node_modules/jest/bin/jest.js"
},
"dependencies": {
"nuxt": "^4.3.1"
"nuxt": "^4.4.2"
},
"devDependencies": {
"@nuxt/test-utils": "latest",
Expand Down
4 changes: 2 additions & 2 deletions examples/app-playwright/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@
"test": "playwright test"
},
"dependencies": {
"nuxt": "^4.3.1"
"nuxt": "^4.4.2"
},
"devDependencies": {
"@nuxt/test-utils": "latest",
"@playwright/test": "1.58.2",
"std-env": "3.10.0"
"std-env": "4.0.0"
}
}
8 changes: 4 additions & 4 deletions examples/app-vitest-browser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
},
"devDependencies": {
"@nuxt/test-utils": "latest",
"@vitest/browser": "4.0.18",
"@vitest/browser-playwright": "4.0.18",
"@vitest/browser": "4.1.0",
"@vitest/browser-playwright": "4.1.0",
"@vue/test-utils": "2.4.6",
"nuxt": "4.3.1",
"nuxt": "4.4.2",
"typescript": "5.9.3",
"vitest": "4.0.18",
"vitest": "4.1.0",
"vitest-browser-vue": "2.0.2"
}
}
6 changes: 3 additions & 3 deletions examples/app-vitest-full/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@
"devDependencies": {
"@nuxt/test-utils": "latest",
"@testing-library/vue": "8.1.0",
"@vitest/ui": "4.0.18",
"@vitest/ui": "4.1.0",
"happy-dom": "20.8.3",
"jsdom": "28.1.0",
"listhen": "1.9.0",
"nuxt": "4.3.1",
"nuxt": "4.4.2",
"typescript": "5.9.3",
"vitest": "4.0.18",
"vitest": "4.1.0",
"vue-tsc": "3.2.5"
},
"dependencies": {
Expand Down
4 changes: 2 additions & 2 deletions examples/app-vitest-workspace/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
"test": "vitest run"
},
"dependencies": {
"nuxt": "^4.3.1"
"nuxt": "^4.4.2"
},
"devDependencies": {
"@nuxt/test-utils": "latest",
"happy-dom": "20.8.3",
"playwright-core": "1.58.2",
"typescript": "5.9.3",
"vitest": "4.0.18"
"vitest": "4.1.0"
}
}
4 changes: 2 additions & 2 deletions examples/app-vitest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"test": "vitest run"
},
"dependencies": {
"nuxt": "^4.3.1"
"nuxt": "^4.4.2"
},
"devDependencies": {
"@nuxt/test-utils": "latest",
Expand All @@ -20,6 +20,6 @@
"playwright-core": "1.58.2",
"tinyglobby": "0.2.15",
"typescript": "5.9.3",
"vitest": "4.0.18"
"vitest": "4.1.0"
}
}
8 changes: 4 additions & 4 deletions examples/content/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"devDependencies": {
"@nuxt/content": "3.12.0",
"@nuxt/test-utils": "latest",
"@vitest/browser": "4.0.18",
"@vitest/browser-playwright": "4.0.18",
"@vitest/browser": "4.1.0",
"@vitest/browser-playwright": "4.1.0",
"better-sqlite3": "12.6.2",
"nuxt": "4.3.1",
"vitest": "4.0.18",
"nuxt": "4.4.2",
"vitest": "4.1.0",
"vitest-browser-vue": "2.0.2"
}
}
4 changes: 2 additions & 2 deletions examples/i18n/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"devDependencies": {
"@nuxt/test-utils": "latest",
"@nuxtjs/i18n": "10.2.3",
"nuxt": "4.3.1",
"vitest": "4.0.18"
"nuxt": "4.4.2",
"vitest": "4.1.0"
}
}
6 changes: 3 additions & 3 deletions examples/module/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@
"test:watch": "vitest watch"
},
"dependencies": {
"@nuxt/kit": "^4.3.1"
"@nuxt/kit": "^4.4.2"
},
"devDependencies": {
"@nuxt/module-builder": "1.0.2",
"@nuxt/test-utils": "latest",
"nuxt": "4.3.1",
"vitest": "4.0.18"
"nuxt": "4.4.2",
"vitest": "4.1.0"
}
}
2 changes: 1 addition & 1 deletion examples/module/playground/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"generate": "nuxt generate"
},
"devDependencies": {
"nuxt": "4.3.1"
"nuxt": "4.4.2"
},
"dependencies": {
"vue": "^3.5.29",
Expand Down
4 changes: 2 additions & 2 deletions examples/nitro-v3/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@
"dependencies": {
"h3": "^2.0.1-rc.14",
"nitro": "https://pkg.pr.new/nitrojs/nitro@00598a8",
"nuxt": "https://pkg.pr.new/nuxt@33005"
"nuxt": "https://pkg.pr.new/nuxt@579db31"
},
"devDependencies": {
"@nuxt/test-utils": "latest",
"happy-dom": "20.8.3",
"playwright-core": "1.58.2",
"tinyglobby": "0.2.15",
"typescript": "5.9.3",
"vitest": "4.0.18"
"vitest": "4.1.0"
}
}
5 changes: 5 additions & 0 deletions examples/nitro-v3/server/api/echo.get.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { defineEventHandler, getQuery } from 'nitro/h3'

export default defineEventHandler((event) => {
return getQuery(event)
})
5 changes: 5 additions & 0 deletions examples/nitro-v3/server/api/echo.post.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { defineEventHandler, readBody } from 'nitro/h3'

export default defineEventHandler(async (event) => {
return await readBody(event)
})
18 changes: 17 additions & 1 deletion examples/nitro-v3/test/server.e2e.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,30 @@ import { fileURLToPath } from 'node:url'
import { $fetch, setup } from '@nuxt/test-utils/e2e'
import { describe, expect, it } from 'vitest'

describe.todo('app', async () => {
describe('app', async () => {
await setup({
rootDir: fileURLToPath(new URL('../', import.meta.url)),
})

it('runs a test', async () => {
const html = await $fetch<string>('/')
expect(html.slice(0, 15)).toMatchInlineSnapshot(`
"<!DOCTYPE html>"
`)
})

describe('server/api', () => {
it('getQuery', async () => {
await expect($fetch('/api/echo', {
query: { message: 'hello' },
})).resolves.toEqual({ message: 'hello' })
})

it('readBody', async () => {
await expect($fetch('/api/echo', {
method: 'post',
body: { message: 'hello' },
})).resolves.toEqual({ message: 'hello' })
})
})
})
2 changes: 1 addition & 1 deletion examples/nitro-v3/vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export default defineConfig({
}),
{
test: {
name: 'unit',
name: 'e2e',
include: ['**/*.e2e.spec.ts'],
},
},
Expand Down
8 changes: 4 additions & 4 deletions examples/nuxt-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@
"devDependencies": {
"@nuxt/test-utils": "latest",
"@nuxt/ui": "4.5.1",
"@vitest/browser": "4.0.18",
"@vitest/browser-playwright": "4.0.18",
"nuxt": "4.3.1",
"@vitest/browser": "4.1.0",
"@vitest/browser-playwright": "4.1.0",
"nuxt": "4.4.2",
"tailwindcss": "4.2.1",
"vitest": "4.0.18",
"vitest": "4.1.0",
"vitest-browser-vue": "2.0.2"
}
}
22 changes: 11 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
"dependencies": {
"@clack/prompts": "1.0.1",
"@nuxt/devtools-kit": "^2.7.0",
"@nuxt/kit": "^3.21.1",
"@nuxt/kit": "^3.21.2",
"c12": "^3.3.3",
"consola": "^3.4.2",
"defu": "^6.1.4",
Expand All @@ -90,7 +90,7 @@
"perfect-debounce": "^2.1.0",
"radix3": "^1.1.2",
"scule": "^1.3.0",
"std-env": "^3.10.0",
"std-env": "^4.0.0",
"tinyexec": "^1.0.2",
"ufo": "^1.6.3",
"unplugin": "^3.0.0",
Expand All @@ -101,23 +101,23 @@
"@cucumber/cucumber": "12.7.0",
"@jest/globals": "30.2.0",
"@nuxt/eslint-config": "1.15.2",
"@nuxt/schema": "4.3.1",
"@nuxt/schema": "4.4.2",
"@playwright/test": "1.58.2",
"@testing-library/vue": "8.1.0",
"@types/bun": "1.3.10",
"@types/estree": "1.0.8",
"@types/jsdom": "28.0.0",
"@types/node": "latest",
"@types/semver": "7.7.1",
"@vitest/browser-playwright": "4.0.18",
"@vitest/browser-playwright": "4.1.0",
"@vue/test-utils": "2.4.6",
"changelogen": "0.6.2",
"compatx": "0.2.0",
"eslint": "10.0.2",
"installed-check": "10.0.1",
"knip": "5.85.0",
"nitropack": "2.13.1",
"nuxt": "4.3.1",
"nuxt": "4.4.2",
"oxc-parser": "0.116.0",
"pkg-pr-new": "0.0.65",
"playwright-core": "1.58.2",
Expand All @@ -126,8 +126,8 @@
"typescript": "5.9.3",
"unbuild": "latest",
"unimport": "6.0.0",
"vite": "7.3.1",
"vitest": "4.0.18",
"vite": "8.0.0",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🌐 Web query:

Vite 8 release notes breaking changes

💡 Result:

Key Vite 8 breaking changes / migration notes (from the official v7→v8 migration guide):

  • New default browser target (build.target: 'baseline-widely-available') bumped to newer baseline versions (Chrome/Edge 111, Firefox 114, Safari 16.4). If you rely on older targets, set build.target explicitly. [1]
  • Bundler/toolchain swap: Vite 8 moves from the esbuild+Rollup split to Rolldown (bundling/dep-optimizer) + Oxc (JS transforms/minify). This can change edge-case build behavior. [1][2]
  • Dep optimization now uses Rolldown: optimizeDeps.esbuildOptions is deprecated in favor of optimizeDeps.rolldownOptions (a compatibility layer auto-converts some options). [1]
  • Transforms/minification by Oxc; esbuild becomes optional:
    • esbuild config is deprecated in favor of oxc (auto-converted where possible). [1]
    • esbuild is no longer a direct dependency; if you (or a plugin) use transformWithEsbuild, you must add esbuild as a devDependency; transformWithEsbuild is deprecated in favor of transformWithOxc. [1]
    • Minification defaults to Oxc; build.minify: 'esbuild' is deprecated and requires installing esbuild. [1]
  • Resolution/interop behavior changes:
    • Removed “format sniffing” heuristic when both browser and module fields exist; Vite now respects resolve.mainFields order. [1]
    • Preserves require() for externalized modules (no longer rewritten to import), with an opt-in plugin if you want conversion. [1]
  • Output / Rollup-compat removals & deprecations:
    • import.meta.url is no longer polyfilled for UMD/IIFE output (replaced with undefined by default). [1]
    • Removed build.rollupOptions.watch.chokidar. [1]
    • build.rollupOptions.output.manualChunks object form removed; function form deprecated in favor of Rolldown codeSplitting. [1]
    • Deprecated build.rollupOptions/worker.rollupOptions in favor of build.rolldownOptions/worker.rolldownOptions (and some other related options become no-ops). [1]
  • Removed deprecated feature: passing a URL to import.meta.hot.accept is no longer supported (pass an id instead). [1]
  • Dropped/limited support due to Rolldown: no system/amd output formats, no ES5-and-below via @vitejs/plugin-legacy, and some Rollup hooks/features aren’t supported. [1]

Sources: Official Vite 8 beta announcement and migration guide. [1][2]


🏁 Script executed:

# First, read the package.json to see the full context around lines 129 and 184-185
wc -l package.json

Repository: nuxt/test-utils

Length of output: 75


🏁 Script executed:

# Read the relevant sections of package.json
sed -n '120,145p' package.json

Repository: nuxt/test-utils

Length of output: 739


🏁 Script executed:

# Also check lines 175-195 to see vite-node
sed -n '175,195p' package.json

Repository: nuxt/test-utils

Length of output: 504


🏁 Script executed:

# Check if Vitest, Nuxt, or vite-node are in use
grep -E "(vitest|nuxt|vite-node)" package.json

Repository: nuxt/test-utils

Length of output: 1136


🏁 Script executed:

# Check for vite config files
fd -e js -e ts -e mjs -e mts | grep -E "(vite|vitest|nuxt)\.config"

Repository: nuxt/test-utils

Length of output: 1346


🏁 Script executed:

# Search for esbuild usage in the codebase
rg "transformWithEsbuild|esbuild" --type js --type ts

Repository: nuxt/test-utils

Length of output: 90


🏁 Script executed:

# Check the esbuild usage in src/e2e/run.ts
cat -n src/e2e/run.ts | grep -B 5 -A 10 "esbuild:"

Repository: nuxt/test-utils

Length of output: 474


🏁 Script executed:

# Check for any vite.config or vitest.config at root level
fd "(vite|vitest)\.config" -d 2

Repository: nuxt/test-utils

Length of output: 41


🏁 Script executed:

# Check for transformWithEsbuild usage anywhere
rg "transformWithEsbuild" --type ts --type js

Repository: nuxt/test-utils

Length of output: 41


🏁 Script executed:

# Look at the broader context of the esbuild config in src/e2e/run.ts
cat -n src/e2e/run.ts | sed -n '35,75p'

Repository: nuxt/test-utils

Length of output: 1097


🏁 Script executed:

# Check if esbuild is a direct dependency (which is no longer the case in Vite 8)
grep -E '"esbuild"' package.json

Repository: nuxt/test-utils

Length of output: 41


🏁 Script executed:

# Search for any transformWithEsbuild usage
rg "transformWithEsbuild|transformWithOxc" --type ts --type js

Repository: nuxt/test-utils

Length of output: 41


Migrate esbuild config to oxc in Vite 8.

The Vite 8 upgrade affects this Nuxt/Vitest project. The esbuild config option in src/e2e/run.ts (lines 48–50) is deprecated in Vite 8; use oxc instead. Vitest 4.0.18 and vite-node 6.0.0 are compatible with Vite 8, but the toolchain shift from esbuild+Rollup to Rolldown+Oxc requires configuration updates. Review the esbuild config for any transformWithEsbuild() calls (deprecated in favor of transformWithOxc()) and ensure oxcOptions replaces deprecated build/esbuild settings.

Also applies to: 184-185

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@package.json` at line 129, Update the Vite 8 migration by replacing any
esbuild-related configuration and APIs in src/e2e/run.ts: locate usages of
transformWithEsbuild() and any esbuild/ build settings and change them to
transformWithOxc() and oxcOptions respectively; update the object keys passed to
the Vite config (replace esbuild/ build.esbuild options with oxc/oxcOptions) and
ensure any transformWithEsbuild-specific options are adapted to the Oxc
equivalents, adjusting imports and types as needed so Vitest/vite-node continue
to work with the Rolldown+Oxc toolchain.

"vitest": "4.1.0",
"vue-router": "5.0.3",
"vue-tsc": "3.2.5"
},
Expand Down Expand Up @@ -176,14 +176,14 @@
},
"resolutions": {
"@cucumber/cucumber": "12.7.0",
"@nuxt/schema": "4.3.1",
"@nuxt/schema": "4.4.2",
"@nuxt/test-utils": "workspace:*",
"@types/node": "24.11.0",
"nitro": "https://pkg.pr.new/nitrojs/nitro@00598a8",
"rollup": "4.59.0",
"vite": "7.3.1",
"vite-node": "5.3.0",
"vitest": "4.0.18",
"vite": "8.0.0",
"vite-node": "6.0.0",
"vitest": "4.1.0",
"vue": "^3.5.29"
},
"engines": {
Expand Down
Loading
Loading