From 1e1870d3f276c5cd0dbc292a1fb091047db0e1a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Sun, 8 Nov 2026 07:59:32 +0000 Subject: [PATCH 01/38] feat(build): quieter Nitro server build output Drop Nitro and the Vite server bundle to warnings only during nuxt build, list failed prerender routes ourselves, and report the server build as one line with its time and size. --log-level verbose keeps the full output. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 7 + packages/nuxt-cli/src/utils/build-progress.ts | 8 +- packages/nuxt-cli/src/utils/formatting.ts | 13 ++ packages/nuxt-cli/src/utils/server-output.ts | 130 ++++++++++++++++++ .../nuxt-cli/test/unit/build-progress.spec.ts | 4 +- .../test/unit/utils/server-output.spec.ts | 125 +++++++++++++++++ 6 files changed, 285 insertions(+), 2 deletions(-) create mode 100644 packages/nuxt-cli/src/utils/server-output.ts create mode 100644 packages/nuxt-cli/test/unit/utils/server-output.spec.ts diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 55b95a2fc..8870b03a7 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -19,6 +19,7 @@ import { resolveRootDir } from '../utils/paths' import { createPhaseReporter, formatPhaseBreakdown } from '../utils/phase-reporter' import { startCpuProfile, stopCpuProfile } from '../utils/profile' import { resolveServerBuild } from '../utils/server-build' +import { quietServerOutput } from '../utils/server-output' import { dotEnvArgs, envNameArgs, extendsArgs, logLevelArgs, profileArgs, rootDirArgs, targetArgs } from './_shared' /** How often a phase repeats itself where there is no animated line. */ @@ -106,6 +107,7 @@ export default defineCommand({ }) progress.attachNuxt(nuxt) + const serverOutput = quietServerOutput(nuxt) showBanner(nuxt) await nuxt.ready() @@ -144,6 +146,11 @@ export default defineCommand({ stopReporting() progress.finish() + const serverSummary = serverOutput.summary() + if (serverSummary) { + logger.success(serverSummary) + } + const breakdown = formatPhaseBreakdown(progress.timings) if (breakdown) { logger.message(styleText('dim', breakdown)) diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index 09c9244bb..3704f5cdb 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -39,6 +39,7 @@ const NITRO_MESSAGES: Record = { } const PRERENDER_HOOK = 'prerender:generate' +const PRERENDERED_HOOK = 'prerender:route' interface HookableLike { beforeEach?: (fn: (event: { name: string, args?: unknown[] }) => void) => void @@ -63,6 +64,8 @@ export class BuildProgress extends PhaseTimeline { * between them. */ #splitBundles = true + /** Routes written so far, the one measure of how far prerendering has got. */ + #prerendered = 0 constructor() { super(BUILD_PHASES) @@ -145,9 +148,12 @@ export class BuildProgress extends PhaseTimeline { else if (name === PRERENDER_HOOK) { const route = (args?.[0] as { route?: string } | undefined)?.route if (route) { - this.setMessage(`Prerendering ${route}`) + this.setMessage(this.#prerendered ? `Prerendering ${route} (${this.#prerendered} done)` : `Prerendering ${route}`) } } + else if (name === PRERENDERED_HOOK) { + this.#prerendered++ + } }) } } diff --git a/packages/nuxt-cli/src/utils/formatting.ts b/packages/nuxt-cli/src/utils/formatting.ts index a6a200fc8..c09ed0f07 100644 --- a/packages/nuxt-cli/src/utils/formatting.ts +++ b/packages/nuxt-cli/src/utils/formatting.ts @@ -132,6 +132,19 @@ export function formatDuration(ms: number): string { : `${minutes}m ${seconds}s` } +const BYTE_UNITS = ['B', 'kB', 'MB', 'GB'] + +/** Format a byte count in decimal units, as Vite and Nitro report sizes (`812 B`, `4.36 kB`, `2.45 MB`). */ +export function formatBytes(bytes: number): string { + let value = Math.max(0, bytes) + let unit = 0 + while (value >= 1000 && unit < BYTE_UNITS.length - 1) { + value /= 1000 + unit++ + } + return unit === 0 ? `${value} B` : `${value.toFixed(2)} ${BYTE_UNITS[unit]}` +} + const AT_MENTION_RE = /\b@([^, ]+)/g const BACKTICK_RE = /`([^`]*)`/g diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts new file mode 100644 index 000000000..de648e03d --- /dev/null +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -0,0 +1,130 @@ +import type { Nuxt } from '@nuxt/schema' +import type { Nitro, PrerenderRoute } from 'nitropack' + +import { readdir, stat } from 'node:fs/promises' +import process from 'node:process' +import { styleText } from 'node:util' + +import { join, relative } from 'pathe' + +import { formatBytes, formatDuration } from './formatting' +import { logger } from './logger' + +/** Nitro's `warn` level: warnings and errors still print, progress and file trees do not. */ +const NITRO_QUIET_LOG_LEVEL = 1 + +export interface ServerOutputReport { + /** The one-line summary of the server build, or nothing for a static-only build. */ + summary: () => string | undefined +} + +/** + * Take over what Nitro and the Vite server bundle print during `nuxt build`, + * leaving warnings and errors in place, and report the server build as a single + * line with its time and size once it is written. + * + * Nothing changes at `--log-level verbose`, or when the project sets a log + * level for Nitro or the Vite server build itself. + */ +export function quietServerOutput(nuxt: Nuxt): ServerOutputReport { + let started: number | undefined + let duration: number | undefined + let size: number | undefined + let prerender: { count: number, duration: number } | undefined + let commands: string[] = [] + let isStatic = false + + if (nuxt.options.logLevel !== 'verbose') { + nuxt.hook('nitro:config', (config) => { + if (nuxt.options.nitro?.logLevel === undefined && Number(config.logLevel ?? 3) > NITRO_QUIET_LOG_LEVEL) { + config.logLevel = NITRO_QUIET_LOG_LEVEL + } + }) + // With the environment API one config builds client and server together, so + // the server output cannot be quietened without the client's. + const vite = nuxt.options.vite as { logLevel?: string, $server?: { logLevel?: string } } | undefined + if (!nuxt.options.experimental?.viteEnvironmentApi && !vite?.logLevel && !vite?.$server?.logLevel) { + nuxt.hook('vite:extendConfig', (config, { isServer }) => { + // Read as well as written by Nuxt's Vite logger on every message, so it + // has to change on this config rather than through a plugin. + if (isServer && config.logLevel !== 'silent') { + (config as { logLevel?: string }).logLevel = 'warn' + } + }) + } + } + + let buildStarted = Date.now() + nuxt.hook('nitro:build:before', () => { + buildStarted = Date.now() + }) + + nuxt.hook('nitro:init', (nitro) => { + let prerendered = 0 + nitro.hooks.hook('prerender:route', (route) => { + if (!route.error) { + prerendered++ + } + }) + nitro.hooks.hook('prerender:done', ({ failedRoutes }) => { + prerender = { count: prerendered, duration: Date.now() - buildStarted } + // Nitro lists these at its `log` level, which the quiet build drops. + if (failedRoutes.length && nuxt.options.logLevel !== 'verbose') { + logger.error(`Failed to prerender ${failedRoutes.length} route${failedRoutes.length === 1 ? '' : 's'}:\n${ + failedRoutes.map(formatFailedRoute).join('\n')}`) + } + }) + nitro.hooks.hook('rollup:before', () => { + started ??= Date.now() + }) + nitro.hooks.hook('compiled', async () => { + isStatic = !!nitro.options.static + duration = Date.now() - (started ?? buildStarted) + size = await directorySize(nitro.options.output.serverDir).catch(() => undefined) + commands = ([ + ['Preview', nitro.options.commands?.preview], + ['Deploy', nitro.options.commands?.deploy], + ] as const).flatMap(([label, command]) => command ? [`${label}: ${styleText('cyan', resolveCommand(command, nitro))}`] : []) + }) + }) + + return { + summary() { + const lines: string[] = [] + if (prerender && prerender.count) { + lines.push(`Prerendered ${prerender.count} route${prerender.count === 1 ? '' : 's'} in ${formatDuration(prerender.duration)}`) + } + if (!isStatic && duration !== undefined) { + lines.push(`Nitro server built in ${formatDuration(duration)}${size === undefined ? '' : styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) + } + if (!lines.length) { + return + } + return [...lines, ...commands.map(line => styleText('dim', line))].join('\n') + }, + } +} + +function formatFailedRoute(route: PrerenderRoute): string { + const status = [route.error?.statusCode, route.error?.statusMessage].filter(Boolean).join(' ') + return ` ${route.route}${status ? styleText('dim', ` (${status})`) : ''}` +} + +/** Fill Nitro's `{{ output.dir }}` placeholders the way Nitro does, relative to the working directory. */ +function resolveCommand(command: string, nitro: Nitro): string { + return command.replace(/\{\{ ?([\w.]+) ?\}\}/g, (match, key: string) => { + const value = key.split('.').reduce((object, part) => object?.[part], nitro.options) + return typeof value === 'string' ? relative(process.cwd(), value) || '.' : match + }) +} + +/** Bytes on disk under `dir`, leaving out source maps as Nitro's own total does. */ +async function directorySize(dir: string): Promise { + let total = 0 + for (const entry of await readdir(dir, { withFileTypes: true, recursive: true })) { + if (entry.isFile() && !entry.name.endsWith('.map')) { + total += (await stat(join(entry.parentPath, entry.name))).size + } + } + return total +} diff --git a/packages/nuxt-cli/test/unit/build-progress.spec.ts b/packages/nuxt-cli/test/unit/build-progress.spec.ts index 8aa216973..8b2106f94 100644 --- a/packages/nuxt-cli/test/unit/build-progress.spec.ts +++ b/packages/nuxt-cli/test/unit/build-progress.spec.ts @@ -86,8 +86,10 @@ describe('build progress', () => { stub.call('nitro:build:before', {}) stub.callNitro('rollup:before') stub.callNitro('prerender:generate', { route: '/about' }) + stub.callNitro('prerender:route', { route: '/about' }) + stub.callNitro('prerender:generate', { route: '/blog' }) - expect(seen).toEqual(['Loading Nuxt config', 'Building Nitro server', 'Bundling Nitro server', 'Prerendering /about']) + expect(seen).toEqual(['Loading Nuxt config', 'Building Nitro server', 'Bundling Nitro server', 'Prerendering /about', 'Prerendering /blog (1 done)']) }) it('should keep phase durations after the build is finished', () => { diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts new file mode 100644 index 000000000..b788fc279 --- /dev/null +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -0,0 +1,125 @@ +import { mkdir, mkdtemp, rm, writeFile } from 'node:fs/promises' +import { tmpdir } from 'node:os' + +import { join } from 'pathe' +import { afterEach, describe, expect, it, vi } from 'vitest' + +import { formatBytes, stripAnsi } from '../../../src/utils/formatting' +import { quietServerOutput } from '../../../src/utils/server-output' + +const mocks = vi.hoisted(() => ({ error: vi.fn() })) +vi.mock('../../../src/utils/logger', () => ({ logger: { error: mocks.error } })) + +type Handler = (...args: any[]) => unknown + +function createHooks() { + const handlers: Record = {} + return { + hook: (name: string, fn: Handler) => void (handlers[name] ||= []).push(fn), + call: async (name: string, ...args: unknown[]) => { + for (const fn of handlers[name] || []) { + await fn(...args) + } + }, + has: (name: string) => !!handlers[name]?.length, + } +} + +function createNuxt(options: Record = {}) { + const hooks = createHooks() + return { nuxt: { options: { logLevel: 'info', nitro: {}, vite: {}, experimental: {}, ...options }, hook: hooks.hook }, hooks } +} + +let dir: string | undefined +afterEach(async () => { + vi.clearAllMocks() + if (dir) { + await rm(dir, { recursive: true, force: true }) + } +}) + +describe('quietServerOutput', () => { + it('drops Nitro and the Vite server bundle to warnings only', async () => { + const { nuxt, hooks } = createNuxt() + quietServerOutput(nuxt as any) + + const nitroConfig = { logLevel: 3 } + await hooks.call('nitro:config', nitroConfig) + const serverConfig = { logLevel: 'info' } + const clientConfig = { logLevel: 'info' } + await hooks.call('vite:extendConfig', serverConfig, { isServer: true, isClient: false }) + await hooks.call('vite:extendConfig', clientConfig, { isServer: false, isClient: true }) + + expect(nitroConfig.logLevel).toBe(1) + expect(serverConfig.logLevel).toBe('warn') + expect(clientConfig.logLevel).toBe('info') + }) + + it('leaves log levels alone when verbose or set by the project', async () => { + const verbose = createNuxt({ logLevel: 'verbose' }) + quietServerOutput(verbose.nuxt as any) + const silent = createNuxt({ logLevel: 'silent' }) + quietServerOutput(silent.nuxt as any) + const configured = createNuxt({ nitro: { logLevel: 3 }, vite: { $server: { logLevel: 'info' } } }) + quietServerOutput(configured.nuxt as any) + + const verboseConfig = { logLevel: 3 } + await verbose.hooks.call('nitro:config', verboseConfig) + const silentConfig = { logLevel: 0 } + await silent.hooks.call('nitro:config', silentConfig) + const configuredConfig = { logLevel: 3 } + await configured.hooks.call('nitro:config', configuredConfig) + + expect([verboseConfig.logLevel, silentConfig.logLevel, configuredConfig.logLevel]).toEqual([3, 0, 3]) + expect(verbose.hooks.has('vite:extendConfig')).toBe(false) + expect(configured.hooks.has('vite:extendConfig')).toBe(false) + }) + + it('summarises the server build and lists failed prerenders', async () => { + dir = await mkdtemp(join(tmpdir(), 'nuxi-server-output-')) + const serverDir = join(dir, 'server') + await mkdir(join(serverDir, 'chunks'), { recursive: true }) + await writeFile(join(serverDir, 'index.mjs'), 'x'.repeat(1500)) + await writeFile(join(serverDir, 'chunks/app.mjs'), 'x'.repeat(1000)) + await writeFile(join(serverDir, 'chunks/app.mjs.map'), 'x'.repeat(50_000)) + + const { nuxt, hooks } = createNuxt() + const report = quietServerOutput(nuxt as any) + const nitroHooks = createHooks() + const nitro = { + options: { output: { serverDir, dir }, commands: { preview: 'node {{ output.serverDir }}/index.mjs' } }, + hooks: nitroHooks, + } + await hooks.call('nitro:init', nitro) + await hooks.call('nitro:build:before', nitro) + await nitroHooks.call('prerender:route', { route: '/' }) + await nitroHooks.call('prerender:route', { route: '/gone', error: { statusCode: 404 } }) + await nitroHooks.call('prerender:done', { failedRoutes: [{ route: '/gone', error: { statusCode: 404, statusMessage: 'Not Found' } }] }) + await nitroHooks.call('rollup:before', nitro) + await nitroHooks.call('compiled', nitro) + + const lines = stripAnsi(report.summary()!).split('\n') + expect(lines[0]).toMatch(/^Prerendered 1 route in \S+$/) + // Source maps are left out, as Nitro leaves them out of its own total. + expect(lines[1]).toMatch(/^Nitro server built in \S+ · 2\.50 kB$/) + expect(lines[2]).toMatch(/^Preview: node \S*server\/index\.mjs$/) + expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 1 route:\n /gone (404 Not Found)') + }) + + it('reports nothing about a server for a static build', async () => { + const { nuxt, hooks } = createNuxt() + const report = quietServerOutput(nuxt as any) + const nitroHooks = createHooks() + const nitro = { options: { static: true, output: { serverDir: '/missing' } }, hooks: nitroHooks } + await hooks.call('nitro:init', nitro) + await nitroHooks.call('compiled', nitro) + + expect(report.summary()).toBeUndefined() + }) +}) + +describe('formatBytes', () => { + it('uses decimal units like Vite and Nitro', () => { + expect([formatBytes(999), formatBytes(1000), formatBytes(2_454_000)]).toEqual(['999 B', '1.00 kB', '2.45 MB']) + }) +}) From 7504daeebc112d6c6b0cdafaa45ea2a5f4c84acf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Sun, 8 Nov 2026 08:31:34 +0000 Subject: [PATCH 02/38] feat(build): name Vite phases client app and server app Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/build-progress.ts | 6 +++--- packages/nuxt-cli/test/unit/build-progress.spec.ts | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index 3704f5cdb..e161eb75c 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -12,8 +12,8 @@ const BUILD_PHASES: readonly Phase[] = [ { id: 'modules', message: 'Setting up modules' }, { id: 'app', message: 'Preparing app' }, { id: 'types', message: 'Generating types' }, - { id: 'client', message: 'Bundling client' }, - { id: 'server', message: 'Bundling server' }, + { id: 'client', message: 'Building client app' }, + { id: 'server', message: 'Building server app' }, { id: 'nitro', message: 'Building Nitro server' }, ] @@ -117,7 +117,7 @@ export class BuildProgress extends PhaseTimeline { nuxt.hooks?.beforeEach?.(({ name, args }) => { const phase = HOOK_PHASES[name] if (phase) { - this.setPhase(phase, phase === 'client' && !this.#splitBundles ? 'Bundling app' : undefined) + this.setPhase(phase, phase === 'client' && !this.#splitBundles ? 'Building client and server app' : undefined) return } if (name === 'vite:configResolved' && this.#splitBundles) { diff --git a/packages/nuxt-cli/test/unit/build-progress.spec.ts b/packages/nuxt-cli/test/unit/build-progress.spec.ts index 8b2106f94..eff103c53 100644 --- a/packages/nuxt-cli/test/unit/build-progress.spec.ts +++ b/packages/nuxt-cli/test/unit/build-progress.spec.ts @@ -55,8 +55,8 @@ describe('build progress', () => { 'Setting up modules', 'Preparing app', 'Generating types', - 'Bundling client', - 'Bundling server', + 'Building client app', + 'Building server app', 'Building Nitro server', ]) expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'client', 'server', 'nitro']) @@ -72,7 +72,7 @@ describe('build progress', () => { stub.call('vite:configResolved', {}, { isClient: true, isServer: false }) stub.call('vite:configResolved', {}, { isClient: false, isServer: true }) - expect(seen).toEqual(['Loading Nuxt config', 'Bundling app']) + expect(seen).toEqual(['Loading Nuxt config', 'Building client and server app']) }) it('should name what the Nitro phase is doing', () => { From e850d212582131c2072164ea20c0a66bf0c7e764 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Sun, 8 Nov 2026 08:43:52 +0000 Subject: [PATCH 03/38] feat(build): name breakdown phases client app and server app Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/build-progress.ts | 17 +++++++++++------ .../nuxt-cli/test/unit/build-progress.spec.ts | 8 ++++++-- 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index e161eb75c..4d0d23acd 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -12,8 +12,8 @@ const BUILD_PHASES: readonly Phase[] = [ { id: 'modules', message: 'Setting up modules' }, { id: 'app', message: 'Preparing app' }, { id: 'types', message: 'Generating types' }, - { id: 'client', message: 'Building client app' }, - { id: 'server', message: 'Building server app' }, + { id: 'client app', message: 'Building client app' }, + { id: 'server app', message: 'Building server app' }, { id: 'nitro', message: 'Building Nitro server' }, ] @@ -21,7 +21,7 @@ const HOOK_PHASES: Record = { 'modules:before': 'modules', 'builder:generateApp': 'app', 'prepare:types': 'types', - 'build:before': 'client', + 'build:before': 'client app', 'nitro:build:before': 'nitro', } @@ -105,6 +105,11 @@ export class BuildProgress extends PhaseTimeline { if (!this.#finished) { this.closePhase() this.#finished = true + // A single build covered both, so the breakdown should not credit the client alone. + const bundle = this.#splitBundles ? undefined : this.timings.find(timing => timing.phase === 'client app') + if (bundle) { + bundle.phase = 'client + server app' + } } } @@ -117,16 +122,16 @@ export class BuildProgress extends PhaseTimeline { nuxt.hooks?.beforeEach?.(({ name, args }) => { const phase = HOOK_PHASES[name] if (phase) { - this.setPhase(phase, phase === 'client' && !this.#splitBundles ? 'Building client and server app' : undefined) + this.setPhase(phase, phase === 'client app' && !this.#splitBundles ? 'Building client and server app' : undefined) return } if (name === 'vite:configResolved' && this.#splitBundles) { const ctx = args?.[1] as { isServer?: boolean } | undefined - this.setPhase(ctx?.isServer ? 'server' : 'client') + this.setPhase(ctx?.isServer ? 'server app' : 'client app') } else if (name === 'webpack:compile') { const ctx = args?.[0] as { name?: string } | undefined - this.setPhase(ctx?.name === 'server' ? 'server' : 'client') + this.setPhase(ctx?.name === 'server' ? 'server app' : 'client app') } else if (name === NITRO_INIT_HOOK) { this.#attachNitro((args?.[0] as { hooks?: HookableLike } | undefined)?.hooks) diff --git a/packages/nuxt-cli/test/unit/build-progress.spec.ts b/packages/nuxt-cli/test/unit/build-progress.spec.ts index eff103c53..3ee74384a 100644 --- a/packages/nuxt-cli/test/unit/build-progress.spec.ts +++ b/packages/nuxt-cli/test/unit/build-progress.spec.ts @@ -59,7 +59,7 @@ describe('build progress', () => { 'Building server app', 'Building Nitro server', ]) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'client', 'server', 'nitro']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'client app', 'server app', 'nitro']) }) it('should not split the bundle phase when a single build covers both environments', () => { @@ -72,7 +72,11 @@ describe('build progress', () => { stub.call('vite:configResolved', {}, { isClient: true, isServer: false }) stub.call('vite:configResolved', {}, { isClient: false, isServer: true }) - expect(seen).toEqual(['Loading Nuxt config', 'Building client and server app']) + stub.call('nitro:build:before', {}) + progress.finish() + + expect(seen).toEqual(['Loading Nuxt config', 'Building client and server app', 'Building Nitro server']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'client + server app', 'nitro']) }) it('should name what the Nitro phase is doing', () => { From f01be13a06b6eb0c0b618d79616ae313880da65c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Sun, 8 Nov 2026 08:44:34 +0000 Subject: [PATCH 04/38] feat(build): name Vite phases app (client) and app (server) Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/build-progress.ts | 16 ++++++++-------- .../nuxt-cli/test/unit/build-progress.spec.ts | 10 +++++----- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index 4d0d23acd..02e972b90 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -12,8 +12,8 @@ const BUILD_PHASES: readonly Phase[] = [ { id: 'modules', message: 'Setting up modules' }, { id: 'app', message: 'Preparing app' }, { id: 'types', message: 'Generating types' }, - { id: 'client app', message: 'Building client app' }, - { id: 'server app', message: 'Building server app' }, + { id: 'app (client)', message: 'Building app (client)' }, + { id: 'app (server)', message: 'Building app (server)' }, { id: 'nitro', message: 'Building Nitro server' }, ] @@ -21,7 +21,7 @@ const HOOK_PHASES: Record = { 'modules:before': 'modules', 'builder:generateApp': 'app', 'prepare:types': 'types', - 'build:before': 'client app', + 'build:before': 'app (client)', 'nitro:build:before': 'nitro', } @@ -106,9 +106,9 @@ export class BuildProgress extends PhaseTimeline { this.closePhase() this.#finished = true // A single build covered both, so the breakdown should not credit the client alone. - const bundle = this.#splitBundles ? undefined : this.timings.find(timing => timing.phase === 'client app') + const bundle = this.#splitBundles ? undefined : this.timings.find(timing => timing.phase === 'app (client)') if (bundle) { - bundle.phase = 'client + server app' + bundle.phase = 'app (client + server)' } } } @@ -122,16 +122,16 @@ export class BuildProgress extends PhaseTimeline { nuxt.hooks?.beforeEach?.(({ name, args }) => { const phase = HOOK_PHASES[name] if (phase) { - this.setPhase(phase, phase === 'client app' && !this.#splitBundles ? 'Building client and server app' : undefined) + this.setPhase(phase, phase === 'app (client)' && !this.#splitBundles ? 'Building app (client + server)' : undefined) return } if (name === 'vite:configResolved' && this.#splitBundles) { const ctx = args?.[1] as { isServer?: boolean } | undefined - this.setPhase(ctx?.isServer ? 'server app' : 'client app') + this.setPhase(ctx?.isServer ? 'app (server)' : 'app (client)') } else if (name === 'webpack:compile') { const ctx = args?.[0] as { name?: string } | undefined - this.setPhase(ctx?.name === 'server' ? 'server app' : 'client app') + this.setPhase(ctx?.name === 'server' ? 'app (server)' : 'app (client)') } else if (name === NITRO_INIT_HOOK) { this.#attachNitro((args?.[0] as { hooks?: HookableLike } | undefined)?.hooks) diff --git a/packages/nuxt-cli/test/unit/build-progress.spec.ts b/packages/nuxt-cli/test/unit/build-progress.spec.ts index 3ee74384a..002954884 100644 --- a/packages/nuxt-cli/test/unit/build-progress.spec.ts +++ b/packages/nuxt-cli/test/unit/build-progress.spec.ts @@ -55,11 +55,11 @@ describe('build progress', () => { 'Setting up modules', 'Preparing app', 'Generating types', - 'Building client app', - 'Building server app', + 'Building app (client)', + 'Building app (server)', 'Building Nitro server', ]) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'client app', 'server app', 'nitro']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'app (client)', 'app (server)', 'nitro']) }) it('should not split the bundle phase when a single build covers both environments', () => { @@ -75,8 +75,8 @@ describe('build progress', () => { stub.call('nitro:build:before', {}) progress.finish() - expect(seen).toEqual(['Loading Nuxt config', 'Building client and server app', 'Building Nitro server']) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'client + server app', 'nitro']) + expect(seen).toEqual(['Loading Nuxt config', 'Building app (client + server)', 'Building Nitro server']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'app (client + server)', 'nitro']) }) it('should name what the Nitro phase is doing', () => { From 49b6f7ca2c92ea898f2a2e5dac184cb02122441f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Sun, 8 Nov 2026 08:47:48 +0000 Subject: [PATCH 05/38] feat(build): name Nitro phase server (nitro) Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/build-progress.ts | 8 ++++---- packages/nuxt-cli/src/utils/server-output.ts | 2 +- packages/nuxt-cli/test/unit/build-progress.spec.ts | 10 +++++----- .../nuxt-cli/test/unit/utils/server-output.spec.ts | 2 +- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index 02e972b90..8cc651145 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -14,7 +14,7 @@ const BUILD_PHASES: readonly Phase[] = [ { id: 'types', message: 'Generating types' }, { id: 'app (client)', message: 'Building app (client)' }, { id: 'app (server)', message: 'Building app (server)' }, - { id: 'nitro', message: 'Building Nitro server' }, + { id: 'server (nitro)', message: 'Building server (nitro)' }, ] const HOOK_PHASES: Record = { @@ -22,7 +22,7 @@ const HOOK_PHASES: Record = { 'builder:generateApp': 'app', 'prepare:types': 'types', 'build:before': 'app (client)', - 'nitro:build:before': 'nitro', + 'nitro:build:before': 'server (nitro)', } /** Nitro builds on its own hooks, which Nuxt's never see. */ @@ -34,7 +34,7 @@ const NITRO_INIT_HOOK = 'nitro:init' * project is the longest silence of the build. */ const NITRO_MESSAGES: Record = { - 'rollup:before': 'Bundling Nitro server', + 'rollup:before': 'Bundling server (nitro)', 'prerender:routes': 'Prerendering routes', } @@ -143,7 +143,7 @@ export class BuildProgress extends PhaseTimeline { hooks?.beforeEach?.(({ name, args }) => { // Nitro's hooks also run while Nuxt is still bundling the app, and those // are not what the build is waiting on. - if (BUILD_PHASES[this.index]!.id !== 'nitro') { + if (BUILD_PHASES[this.index]!.id !== 'server (nitro)') { return } const message = NITRO_MESSAGES[name] diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index de648e03d..e97c00919 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -95,7 +95,7 @@ export function quietServerOutput(nuxt: Nuxt): ServerOutputReport { lines.push(`Prerendered ${prerender.count} route${prerender.count === 1 ? '' : 's'} in ${formatDuration(prerender.duration)}`) } if (!isStatic && duration !== undefined) { - lines.push(`Nitro server built in ${formatDuration(duration)}${size === undefined ? '' : styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) + lines.push(`Server (nitro) built in ${formatDuration(duration)}${size === undefined ? '' : styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) } if (!lines.length) { return diff --git a/packages/nuxt-cli/test/unit/build-progress.spec.ts b/packages/nuxt-cli/test/unit/build-progress.spec.ts index 002954884..9f1c47da8 100644 --- a/packages/nuxt-cli/test/unit/build-progress.spec.ts +++ b/packages/nuxt-cli/test/unit/build-progress.spec.ts @@ -57,9 +57,9 @@ describe('build progress', () => { 'Generating types', 'Building app (client)', 'Building app (server)', - 'Building Nitro server', + 'Building server (nitro)', ]) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'app (client)', 'app (server)', 'nitro']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'app (client)', 'app (server)', 'server (nitro)']) }) it('should not split the bundle phase when a single build covers both environments', () => { @@ -75,8 +75,8 @@ describe('build progress', () => { stub.call('nitro:build:before', {}) progress.finish() - expect(seen).toEqual(['Loading Nuxt config', 'Building app (client + server)', 'Building Nitro server']) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'app (client + server)', 'nitro']) + expect(seen).toEqual(['Loading Nuxt config', 'Building app (client + server)', 'Building server (nitro)']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'app (client + server)', 'server (nitro)']) }) it('should name what the Nitro phase is doing', () => { @@ -93,7 +93,7 @@ describe('build progress', () => { stub.callNitro('prerender:route', { route: '/about' }) stub.callNitro('prerender:generate', { route: '/blog' }) - expect(seen).toEqual(['Loading Nuxt config', 'Building Nitro server', 'Bundling Nitro server', 'Prerendering /about', 'Prerendering /blog (1 done)']) + expect(seen).toEqual(['Loading Nuxt config', 'Building server (nitro)', 'Bundling server (nitro)', 'Prerendering /about', 'Prerendering /blog (1 done)']) }) it('should keep phase durations after the build is finished', () => { diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index b788fc279..0bac6da63 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -101,7 +101,7 @@ describe('quietServerOutput', () => { const lines = stripAnsi(report.summary()!).split('\n') expect(lines[0]).toMatch(/^Prerendered 1 route in \S+$/) // Source maps are left out, as Nitro leaves them out of its own total. - expect(lines[1]).toMatch(/^Nitro server built in \S+ · 2\.50 kB$/) + expect(lines[1]).toMatch(/^Server \(nitro\) built in \S+ · 2\.50 kB$/) expect(lines[2]).toMatch(/^Preview: node \S*server\/index\.mjs$/) expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 1 route:\n /gone (404 Not Found)') }) From 1638406ef41993ff82e3135f3965a001446753e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Sun, 8 Nov 2026 08:56:06 +0000 Subject: [PATCH 06/38] fix(build): time Vite client and server builds from the build itself Server builders such as @nuxt/vite-server switch on the environment API during setup, so the client/server split can no longer be decided when the CLI attaches. A small Vite plugin now reports each environment as it starts building, which also splits the environment API build into app (client) and app (server). Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/build-progress.ts | 51 ++++++++++++------- .../nuxt-cli/test/unit/build-progress.spec.ts | 49 +++++++++++++----- 2 files changed, 69 insertions(+), 31 deletions(-) diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index 8cc651145..5343087ba 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -46,10 +46,13 @@ interface HookableLike { } interface NuxtLike { - options?: { experimental?: { viteEnvironmentApi?: boolean } } + hook?: (name: 'vite:extendConfig', fn: (config: { plugins?: unknown[] }) => void) => unknown hooks?: HookableLike } +/** Names the Vite plugin that reports which environment is being built, so it is added once per config. */ +const VITE_PLUGIN_NAME = 'nuxi:build-progress' + /** * Tracks how far a production build has got, so the same transient phase line * `nuxt dev` shows can report `nuxt build`, and the completion summary can list @@ -58,12 +61,6 @@ interface NuxtLike { export class BuildProgress extends PhaseTimeline { #message = BUILD_PHASES[0]!.message #finished = false - /** - * With the Vite environment API a single build covers both environments, so - * the client and server configs resolve up front and cannot mark the boundary - * between them. - */ - #splitBundles = true /** Routes written so far, the one measure of how far prerendering has got. */ #prerendered = 0 @@ -105,11 +102,6 @@ export class BuildProgress extends PhaseTimeline { if (!this.#finished) { this.closePhase() this.#finished = true - // A single build covered both, so the breakdown should not credit the client alone. - const bundle = this.#splitBundles ? undefined : this.timings.find(timing => timing.phase === 'app (client)') - if (bundle) { - bundle.phase = 'app (client + server)' - } } } @@ -118,18 +110,22 @@ export class BuildProgress extends PhaseTimeline { * the project's own build rather than a schedule guessed by the CLI. */ attachNuxt(nuxt: NuxtLike): void { - this.#splitBundles = !nuxt.options?.experimental?.viteEnvironmentApi + // Vite configs resolve before anything is bundled, and with the environment + // API (which a server builder such as `@nuxt/vite-server` can switch on during + // setup) one config builds both environments. Only the build itself knows + // which environment it has reached. + nuxt.hook?.('vite:extendConfig', (config) => { + if (config.plugins && !config.plugins.some(plugin => (plugin as { name?: string } | null)?.name === VITE_PLUGIN_NAME)) { + config.plugins.push(this.#vitePlugin()) + } + }) nuxt.hooks?.beforeEach?.(({ name, args }) => { const phase = HOOK_PHASES[name] if (phase) { - this.setPhase(phase, phase === 'app (client)' && !this.#splitBundles ? 'Building app (client + server)' : undefined) + this.setPhase(phase) return } - if (name === 'vite:configResolved' && this.#splitBundles) { - const ctx = args?.[1] as { isServer?: boolean } | undefined - this.setPhase(ctx?.isServer ? 'app (server)' : 'app (client)') - } - else if (name === 'webpack:compile') { + if (name === 'webpack:compile') { const ctx = args?.[0] as { name?: string } | undefined this.setPhase(ctx?.name === 'server' ? 'app (server)' : 'app (client)') } @@ -139,6 +135,23 @@ export class BuildProgress extends PhaseTimeline { }) } + #vitePlugin() { + let ssr = false + const setPhase = (id: string) => this.setPhase(id) + return { + name: VITE_PLUGIN_NAME, + apply: 'build' as const, + // Before Vite 6 each environment has a config of its own. + configResolved(config: { build?: { ssr?: unknown } }) { + ssr = !!config.build?.ssr + }, + buildStart(this: { environment?: { config?: { consumer?: string } } }) { + const consumer = this.environment?.config?.consumer ?? (ssr ? 'server' : 'client') + setPhase(consumer === 'server' ? 'app (server)' : 'app (client)') + }, + } + } + #attachNitro(hooks: HookableLike | undefined): void { hooks?.beforeEach?.(({ name, args }) => { // Nitro's hooks also run while Nuxt is still bundling the app, and those diff --git a/packages/nuxt-cli/test/unit/build-progress.spec.ts b/packages/nuxt-cli/test/unit/build-progress.spec.ts index 9f1c47da8..f2d26ef57 100644 --- a/packages/nuxt-cli/test/unit/build-progress.spec.ts +++ b/packages/nuxt-cli/test/unit/build-progress.spec.ts @@ -6,12 +6,19 @@ import { BuildProgress } from '../../src/utils/build-progress' type HookHandler = (event: { name: string, args?: unknown[] }) => void -function nuxtStub(options: { viteEnvironmentApi?: boolean } = {}) { +interface VitePlugin { + name: string + configResolved: (config: { build?: { ssr?: unknown } }) => void + buildStart: (this: { environment?: { config: { consumer: string } } }) => void +} + +function nuxtStub() { const handlers: HookHandler[] = [] const nitroHandlers: HookHandler[] = [] + const extendConfig: Array<(config: { plugins: unknown[] }) => void> = [] return { nuxt: { - options: { experimental: { viteEnvironmentApi: options.viteEnvironmentApi } }, + hook: (_name: 'vite:extendConfig', fn: (config: { plugins: unknown[] }) => void) => void extendConfig.push(fn), hooks: { beforeEach: (fn: HookHandler) => void handlers.push(fn) }, }, call(name: string, ...args: unknown[]) { @@ -19,6 +26,13 @@ function nuxtStub(options: { viteEnvironmentApi?: boolean } = {}) { handler({ name, args }) } }, + /** Run `vite:extendConfig` on a config and return the plugins the CLI added to it. */ + extendVite(config: { plugins: unknown[] }): VitePlugin[] { + for (const fn of extendConfig) { + fn(config) + } + return config.plugins as VitePlugin[] + }, nitro: { hooks: { beforeEach: (fn: HookHandler) => void nitroHandlers.push(fn) } }, callNitro(name: string, ...args: unknown[]) { for (const handler of nitroHandlers) { @@ -45,8 +59,13 @@ describe('build progress', () => { stub.call('builder:generateApp') stub.call('prepare:types') stub.call('build:before') - stub.call('vite:configResolved', {}, { isClient: true, isServer: false }) - stub.call('vite:configResolved', {}, { isClient: false, isServer: true }) + // Without the environment API, client and server each have a config and a build. + const [client] = stub.extendVite({ plugins: [] }) + const [server] = stub.extendVite({ plugins: [] }) + client!.configResolved({ build: {} }) + server!.configResolved({ build: { ssr: true } }) + client!.buildStart.call({}) + server!.buildStart.call({}) stub.call('nitro:build:before', {}) progress.finish() @@ -62,21 +81,27 @@ describe('build progress', () => { expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'app (client)', 'app (server)', 'server (nitro)']) }) - it('should not split the bundle phase when a single build covers both environments', () => { + it('should split the bundle phase when a single config builds both environments', () => { const progress = new BuildProgress() - const stub = nuxtStub({ viteEnvironmentApi: true }) + const stub = nuxtStub() progress.attachNuxt(stub.nuxt) const seen = messages(progress) stub.call('build:before') - stub.call('vite:configResolved', {}, { isClient: true, isServer: false }) - stub.call('vite:configResolved', {}, { isClient: false, isServer: true }) - - stub.call('nitro:build:before', {}) + // The environment API extends one shared config once per environment, up front. + const config = { plugins: [] } + stub.extendVite(config) + const plugins = stub.extendVite(config) + expect(plugins).toHaveLength(1) + expect(seen.at(-1)).toBe('Building app (client)') + + plugins[0]!.configResolved({ build: {} }) + plugins[0]!.buildStart.call({ environment: { config: { consumer: 'client' } } }) + plugins[0]!.buildStart.call({ environment: { config: { consumer: 'server' } } }) progress.finish() - expect(seen).toEqual(['Loading Nuxt config', 'Building app (client + server)', 'Building server (nitro)']) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'app (client + server)', 'server (nitro)']) + expect(seen).toEqual(['Loading Nuxt config', 'Building app (client)', 'Building app (server)']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'app (client)', 'app (server)']) }) it('should name what the Nitro phase is doing', () => { From d2972afa950dcb2a1019db44cd96d0c721cf3c0a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Sun, 8 Nov 2026 09:06:39 +0000 Subject: [PATCH 07/38] feat(build): quiet server output for Nitro 3 and @nuxt/vite-server Nitro 3 and @nuxt/vite-server build the server as a Vite environment next to the app. A Vite plugin now mutes Vite's info output while a server environment builds, times the server build from its environment, and reports the vite-server output as Server (vite). The banner leaves Nitro out when it is not the server builder, and the preview hint points at nuxt preview, which works for every builder. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/build-progress.ts | 17 +- packages/nuxt-cli/src/utils/server-output.ts | 192 ++++++++++++++---- .../test/unit/utils/server-output.spec.ts | 70 ++++++- 3 files changed, 231 insertions(+), 48 deletions(-) diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index 5343087ba..ad8699a78 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -46,6 +46,7 @@ interface HookableLike { } interface NuxtLike { + options?: { experimental?: { nitroViteEnvironment?: boolean } } hook?: (name: 'vite:extendConfig', fn: (config: { plugins?: unknown[] }) => void) => unknown hooks?: HookableLike } @@ -53,6 +54,9 @@ interface NuxtLike { /** Names the Vite plugin that reports which environment is being built, so it is added once per config. */ const VITE_PLUGIN_NAME = 'nuxi:build-progress' +/** The Vite environment Nitro 3 builds the server in. */ +const NITRO_ENVIRONMENT = 'nitro' + /** * Tracks how far a production build has got, so the same transient phase line * `nuxt dev` shows can report `nuxt build`, and the completion summary can list @@ -121,10 +125,15 @@ export class BuildProgress extends PhaseTimeline { }) nuxt.hooks?.beforeEach?.(({ name, args }) => { const phase = HOOK_PHASES[name] - if (phase) { + // Nitro 3 can build as a Vite environment, after the app, and is then + // reported by the Vite plugin when its environment starts. + if (phase && !(name === 'nitro:build:before' && nuxt.options?.experimental?.nitroViteEnvironment)) { this.setPhase(phase) return } + if (phase) { + return + } if (name === 'webpack:compile') { const ctx = args?.[0] as { name?: string } | undefined this.setPhase(ctx?.name === 'server' ? 'app (server)' : 'app (client)') @@ -145,7 +154,11 @@ export class BuildProgress extends PhaseTimeline { configResolved(config: { build?: { ssr?: unknown } }) { ssr = !!config.build?.ssr }, - buildStart(this: { environment?: { config?: { consumer?: string } } }) { + buildStart(this: { environment?: { name: string, config?: { consumer?: string } } }) { + if (this.environment?.name === NITRO_ENVIRONMENT) { + setPhase('server (nitro)') + return + } const consumer = this.environment?.config?.consumer ?? (ssr ? 'server' : 'client') setPhase(consumer === 'server' ? 'app (server)' : 'app (client)') }, diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index e97c00919..db9fcc0b5 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -7,50 +7,147 @@ import { styleText } from 'node:util' import { join, relative } from 'pathe' -import { formatBytes, formatDuration } from './formatting' +import { formatBytes, formatDuration, stripAnsi } from './formatting' import { logger } from './logger' /** Nitro's `warn` level: warnings and errors still print, progress and file trees do not. */ const NITRO_QUIET_LOG_LEVEL = 1 +/** The Vite environment Nitro 3 builds the server in. */ +const NITRO_ENVIRONMENT = 'nitro' + +const VITE_PLUGIN_NAME = 'nuxi:server-output' + +/** The line Vite opens each environment's build with, e.g. `vite v8.3.5 building ssr environment for production...`. */ +const ENVIRONMENT_BUILD_RE = /building (\S+) environment for/ + +/** Source maps, which `@nuxt/vite-server` writes as `*.map.json`. */ +const SOURCE_MAP_RE = /\.map(?:\.json)?$/ + export interface ServerOutputReport { /** The one-line summary of the server build, or nothing for a static-only build. */ summary: () => string | undefined } +interface ViteLogger { + info: (message: string, options?: unknown) => void +} + +interface ResolvedViteConfig { + logger: ViteLogger + environments?: Record +} + +interface ViteBuildContext { + environment?: { name: string, config: { consumer?: string } } +} + +/** Nuxt fields read optimistically: the server build descriptor only exists in recent Nuxt. */ +interface MaybeServerBuild { + serverBuild?: { name: string, output: { dir: () => string } } +} + /** - * Take over what Nitro and the Vite server bundle print during `nuxt build`, - * leaving warnings and errors in place, and report the server build as a single - * line with its time and size once it is written. + * Take over what the server build prints during `nuxt build`, leaving warnings + * and errors in place, and report it as a single line with its time and size + * once it is written. + * + * Nitro 2 builds the server with its own bundler; Nitro 3 and `@nuxt/vite-server` + * build it as a Vite environment, alongside the app. Either way the CLI keeps + * Vite's file lists for the client only. * * Nothing changes at `--log-level verbose`, or when the project sets a log - * level for Nitro or the Vite server build itself. + * level for Nitro or Vite itself. */ export function quietServerOutput(nuxt: Nuxt): ServerOutputReport { + const quiet = nuxt.options.logLevel !== 'verbose' + let usesNitro = false let started: number | undefined let duration: number | undefined let size: number | undefined let prerender: { count: number, duration: number } | undefined - let commands: string[] = [] + let deploy: string | undefined let isStatic = false - if (nuxt.options.logLevel !== 'verbose') { + const finish = async (dir: string | undefined) => { + if (started === undefined || duration !== undefined) { + return + } + duration = Date.now() - started + size = dir ? await directorySize(dir).catch(() => undefined) : undefined + } + + if (quiet) { nuxt.hook('nitro:config', (config) => { if (nuxt.options.nitro?.logLevel === undefined && Number(config.logLevel ?? 3) > NITRO_QUIET_LOG_LEVEL) { config.logLevel = NITRO_QUIET_LOG_LEVEL } }) - // With the environment API one config builds client and server together, so - // the server output cannot be quietened without the client's. - const vite = nuxt.options.vite as { logLevel?: string, $server?: { logLevel?: string } } | undefined - if (!nuxt.options.experimental?.viteEnvironmentApi && !vite?.logLevel && !vite?.$server?.logLevel) { - nuxt.hook('vite:extendConfig', (config, { isServer }) => { - // Read as well as written by Nuxt's Vite logger on every message, so it - // has to change on this config rather than through a plugin. - if (isServer && config.logLevel !== 'silent') { - (config as { logLevel?: string }).logLevel = 'warn' + } + + const vite = nuxt.options.vite as { logLevel?: string, $server?: { logLevel?: string } } | undefined + const quietVite = quiet && !vite?.logLevel && !vite?.$server?.logLevel + nuxt.hook('vite:extendConfig', (config, { isServer }) => { + // A config of its own builds nothing but the server, so its log level can + // drop too, which also silences the progress lines Vite's native reporter + // writes straight to the terminal. With the environment API one config + // builds every environment, and is read at hook time because a server + // builder may switch the API on during setup. + if (quietVite && isServer && !nuxt.options.experimental?.viteEnvironmentApi && config.logLevel !== 'silent') { + (config as { logLevel?: string }).logLevel = 'warn' + } + // The environment API extends one shared config once per environment. + const plugins = config.plugins as unknown[] | undefined + if (plugins && !plugins.some(plugin => (plugin as { name?: string } | null)?.name === VITE_PLUGIN_NAME)) { + plugins.push(createVitePlugin()) + } + }) + + function createVitePlugin() { + const servers = new Set() + let muted = false + return { + name: VITE_PLUGIN_NAME, + apply: 'build' as const, + configResolved(config: ResolvedViteConfig) { + for (const [name, environment] of Object.entries(config.environments ?? {})) { + if (environment.consumer === 'server') { + servers.add(name) + } + } + if (!quietVite) { + return + } + // Vite reports each environment through the one logger, at a single log + // level. Muting its info messages while a server environment builds keeps + // the client's file list and every warning. + const info = config.logger.info.bind(config.logger) + config.logger.info = (message, options) => { + const environment = typeof message === 'string' ? stripAnsi(message).match(ENVIRONMENT_BUILD_RE)?.[1] : undefined + if (environment) { + muted = servers.has(environment) + } + if (!muted) { + info(message, options) + } + } + }, + buildStart(this: ViteBuildContext) { + const environment = this.environment + if (!environment) { + return + } + muted = environment.config.consumer === 'server' && quietVite + // The Vite environment that writes the server output, where there is one. + // Nitro 3 also runs its Rollup hooks before the app is bundled, so its + // environment starting is what marks the server build. + if (environment.name === NITRO_ENVIRONMENT) { + started = Date.now() + } + else if (!usesNitro && environment.config.consumer === 'server') { + started ??= Date.now() } - }) + }, } } @@ -58,33 +155,45 @@ export function quietServerOutput(nuxt: Nuxt): ServerOutputReport { nuxt.hook('nitro:build:before', () => { buildStarted = Date.now() }) + let prerenderStarted: number | undefined + + // Without Nitro the Vite server build is the whole server output. + nuxt.hook('build:done', async () => { + if (!usesNitro) { + const dir = (nuxt as unknown as MaybeServerBuild).serverBuild?.output.dir() + await finish(dir ? join(dir, 'server') : undefined) + } + }) nuxt.hook('nitro:init', (nitro) => { + usesNitro = true let prerendered = 0 + // Nitro 3 prerenders after the app is bundled, so the clock starts with the prerenderer. + nitro.hooks.hook('prerender:init', () => { + prerenderStarted = Date.now() + }) nitro.hooks.hook('prerender:route', (route) => { if (!route.error) { prerendered++ } }) nitro.hooks.hook('prerender:done', ({ failedRoutes }) => { - prerender = { count: prerendered, duration: Date.now() - buildStarted } + prerender = { count: prerendered, duration: Date.now() - (prerenderStarted ?? buildStarted) } // Nitro lists these at its `log` level, which the quiet build drops. - if (failedRoutes.length && nuxt.options.logLevel !== 'verbose') { + if (failedRoutes.length && quiet) { logger.error(`Failed to prerender ${failedRoutes.length} route${failedRoutes.length === 1 ? '' : 's'}:\n${ failedRoutes.map(formatFailedRoute).join('\n')}`) } }) + // Nitro 2 bundles with its own Rollup build. nitro.hooks.hook('rollup:before', () => { started ??= Date.now() }) nitro.hooks.hook('compiled', async () => { isStatic = !!nitro.options.static - duration = Date.now() - (started ?? buildStarted) - size = await directorySize(nitro.options.output.serverDir).catch(() => undefined) - commands = ([ - ['Preview', nitro.options.commands?.preview], - ['Deploy', nitro.options.commands?.deploy], - ] as const).flatMap(([label, command]) => command ? [`${label}: ${styleText('cyan', resolveCommand(command, nitro))}`] : []) + started ??= buildStarted + deploy = nitro.options.commands?.deploy ? resolveDeployCommand(nitro) : undefined + await finish(nitro.options.output.serverDir) }) }) @@ -94,13 +203,16 @@ export function quietServerOutput(nuxt: Nuxt): ServerOutputReport { if (prerender && prerender.count) { lines.push(`Prerendered ${prerender.count} route${prerender.count === 1 ? '' : 's'} in ${formatDuration(prerender.duration)}`) } - if (!isStatic && duration !== undefined) { - lines.push(`Server (nitro) built in ${formatDuration(duration)}${size === undefined ? '' : styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) - } - if (!lines.length) { - return + // No size means nothing was written, as in a static build. + if (!isStatic && duration !== undefined && size !== undefined) { + const builder = usesNitro ? 'nitro' : (nuxt as unknown as MaybeServerBuild).serverBuild?.name || 'server' + lines.push(`Server (${builder}) built in ${formatDuration(duration)}${size === undefined ? '' : styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) + lines.push(styleText('dim', `Preview: ${styleText('cyan', 'npx nuxt preview')}`)) + if (deploy) { + lines.push(styleText('dim', `Deploy: ${styleText('cyan', deploy)}`)) + } } - return [...lines, ...commands.map(line => styleText('dim', line))].join('\n') + return lines.length ? lines.join('\n') : undefined }, } } @@ -110,10 +222,18 @@ function formatFailedRoute(route: PrerenderRoute): string { return ` ${route.route}${status ? styleText('dim', ` (${status})`) : ''}` } -/** Fill Nitro's `{{ output.dir }}` placeholders the way Nitro does, relative to the working directory. */ -function resolveCommand(command: string, nitro: Nitro): string { - return command.replace(/\{\{ ?([\w.]+) ?\}\}/g, (match, key: string) => { - const value = key.split('.').reduce((object, part) => object?.[part], nitro.options) +/** + * The deploy command Nitro would print. Nitro 2 fills `{{ output.dir }}` + * placeholders relative to the working directory; Nitro 3 names a command of + * its own. + */ +function resolveDeployCommand(nitro: Nitro): string { + const options = nitro.options as Nitro['options'] & { builder?: string, framework?: { deployCommand?: string } } + if (options.builder) { + return options.framework?.deployCommand || 'npx nitro deploy --prebuilt' + } + return options.commands.deploy!.replace(/\{\{ ?([\w.]+) ?\}\}/g, (match, key: string) => { + const value = key.split('.').reduce((object, part) => object?.[part], options) return typeof value === 'string' ? relative(process.cwd(), value) || '.' : match }) } @@ -122,7 +242,7 @@ function resolveCommand(command: string, nitro: Nitro): string { async function directorySize(dir: string): Promise { let total = 0 for (const entry of await readdir(dir, { withFileTypes: true, recursive: true })) { - if (entry.isFile() && !entry.name.endsWith('.map')) { + if (entry.isFile() && !SOURCE_MAP_RE.test(entry.name)) { total += (await stat(join(entry.parentPath, entry.name))).size } } diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index 0bac6da63..ad66befcb 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -38,21 +38,47 @@ afterEach(async () => { } }) +/** Run `vite:extendConfig` and resolve the plugin the CLI added, against a logger that records what it lets through. */ +async function resolveVitePlugin(hooks: ReturnType) { + const config = { plugins: [] as any[] } + await hooks.call('vite:extendConfig', config, { isClient: true, isServer: false }) + const plugin = config.plugins[0] + const printed: string[] = [] + const logger = { info: (message: string) => void printed.push(message) } + plugin.configResolved({ logger, environments: { client: { consumer: 'client' }, ssr: { consumer: 'server' }, nitro: { consumer: 'server' } } }) + return { plugin, logger, printed } +} + describe('quietServerOutput', () => { - it('drops Nitro and the Vite server bundle to warnings only', async () => { + it('drops Nitro to warnings only', async () => { const { nuxt, hooks } = createNuxt() quietServerOutput(nuxt as any) const nitroConfig = { logLevel: 3 } await hooks.call('nitro:config', nitroConfig) - const serverConfig = { logLevel: 'info' } - const clientConfig = { logLevel: 'info' } - await hooks.call('vite:extendConfig', serverConfig, { isServer: true, isClient: false }) - await hooks.call('vite:extendConfig', clientConfig, { isServer: false, isClient: true }) expect(nitroConfig.logLevel).toBe(1) - expect(serverConfig.logLevel).toBe('warn') - expect(clientConfig.logLevel).toBe('info') + }) + + it('keeps Vite\'s output for the client environment only', async () => { + const { nuxt, hooks } = createNuxt() + quietServerOutput(nuxt as any) + const { plugin, logger, printed } = await resolveVitePlugin(hooks) + + // Vite announces each environment before its plugins start. + logger.info('\u001B[36mvite v8.3.5 \u001B[32mbuilding client environment for production...\u001B[39m') + plugin.buildStart.call({ environment: { name: 'client', config: { consumer: 'client' } } }) + logger.info('.output/public/_nuxt/entry.js') + logger.info('vite v8.3.5 building ssr environment for production...') + plugin.buildStart.call({ environment: { name: 'ssr', config: { consumer: 'server' } } }) + logger.info('.nuxt/vite/services/ssr/server.mjs') + logger.info('vite v8.3.5 building nitro environment for production...') + logger.info('.output/server/index.mjs') + + expect(printed.map(line => stripAnsi(line))).toEqual([ + 'vite v8.3.5 building client environment for production...', + '.output/public/_nuxt/entry.js', + ]) }) it('leaves log levels alone when verbose or set by the project', async () => { @@ -71,8 +97,12 @@ describe('quietServerOutput', () => { await configured.hooks.call('nitro:config', configuredConfig) expect([verboseConfig.logLevel, silentConfig.logLevel, configuredConfig.logLevel]).toEqual([3, 0, 3]) - expect(verbose.hooks.has('vite:extendConfig')).toBe(false) - expect(configured.hooks.has('vite:extendConfig')).toBe(false) + for (const { hooks } of [verbose, configured]) { + const { logger, printed } = await resolveVitePlugin(hooks) + logger.info('vite v8.3.5 building ssr environment for production...') + logger.info('.nuxt/vite/services/ssr/server.mjs') + expect(printed).toHaveLength(2) + } }) it('summarises the server build and lists failed prerenders', async () => { @@ -102,10 +132,30 @@ describe('quietServerOutput', () => { expect(lines[0]).toMatch(/^Prerendered 1 route in \S+$/) // Source maps are left out, as Nitro leaves them out of its own total. expect(lines[1]).toMatch(/^Server \(nitro\) built in \S+ · 2\.50 kB$/) - expect(lines[2]).toMatch(/^Preview: node \S*server\/index\.mjs$/) + expect(lines[2]).toBe('Preview: npx nuxt preview') expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 1 route:\n /gone (404 Not Found)') }) + it('reports a server built by Vite when Nitro is not the server builder', async () => { + dir = await mkdtemp(join(tmpdir(), 'nuxi-server-output-')) + await mkdir(join(dir, 'server'), { recursive: true }) + await writeFile(join(dir, 'server/index.mjs'), 'x'.repeat(1200)) + await writeFile(join(dir, 'server/index.mjs.map.json'), 'x'.repeat(40_000)) + + const { nuxt, hooks } = createNuxt() + Object.assign(nuxt, { serverBuild: { name: 'vite', output: { dir: () => dir } } }) + const report = quietServerOutput(nuxt as any) + const { plugin } = await resolveVitePlugin(hooks) + plugin.buildStart.call({ environment: { name: 'client', config: { consumer: 'client' } } }) + plugin.buildStart.call({ environment: { name: 'ssr', config: { consumer: 'server' } } }) + await hooks.call('build:done') + + expect(stripAnsi(report.summary()!).split('\n')).toEqual([ + expect.stringMatching(/^Server \(vite\) built in \S+ · 1\.20 kB$/), + 'Preview: npx nuxt preview', + ]) + }) + it('reports nothing about a server for a static build', async () => { const { nuxt, hooks } = createNuxt() const report = quietServerOutput(nuxt as any) From a839115a6d059265eddcb49ff8e4b26f26633217 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Mon, 9 Nov 2026 22:24:55 +0000 Subject: [PATCH 08/38] revert(build): move banner change to its own pull request Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/banner.ts | 13 +++---------- packages/nuxt-cli/test/unit/utils/banner.spec.ts | 10 ---------- 2 files changed, 3 insertions(+), 20 deletions(-) diff --git a/packages/nuxt-cli/src/utils/banner.ts b/packages/nuxt-cli/src/utils/banner.ts index 8613dfc40..59d17c21e 100644 --- a/packages/nuxt-cli/src/utils/banner.ts +++ b/packages/nuxt-cli/src/utils/banner.ts @@ -5,7 +5,6 @@ import { styleText } from 'node:util' import { logger } from './logger' import { getNitroVersion } from './nitro' import { getNuxtPkgVersion, getPkgJSON, getPkgVersion } from './pkg' -import { getServerBuilderName } from './server-build' export function getBuilder(cwd: string, builder: Exclude): { name: string, version: string, provider?: { name: string, version: string } } { switch (builder) { @@ -31,12 +30,7 @@ export function getBuilder(cwd: string, builder: Exclude { `) }) - it('should omit nitro when another server builder is configured', async () => { - const renderer = await render(() => - showBanner({ _version: '4.4.6', options: { rootDir: '/any', builder: 'vite', server: { builder: '@nuxt/vite-server' } } } as unknown as Nuxt)) - - expect(screen(renderer)).toMatchInlineSnapshot(` - "│ - ● Nuxt 4.4.6 (with Vite 7.3.1 and Vue 3.5.39)" - `) - }) - it('should identify Vite+ as the Vite provider', async () => { const renderer = await render(() => showBanner({ _version: '4.4.6', options: { rootDir: '/vite-plus', builder: 'vite' } } as unknown as Nuxt)) From 487ac6c982895573eea3b4b42fdf965fde94229d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Tue, 10 Nov 2026 11:34:13 +0000 Subject: [PATCH 09/38] feat(build): name the bundling phases bundle (client), bundle (server) and bundle (nitro) app (client) and app (server) read as part of the app phase that generates templates. The three phases now say what they bundle, which also matches the bundle phase nuxt dev already reports. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/build-progress.ts | 20 +++++++++---------- .../nuxt-cli/test/unit/build-progress.spec.ts | 16 +++++++-------- 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index ad8699a78..537134704 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -12,17 +12,17 @@ const BUILD_PHASES: readonly Phase[] = [ { id: 'modules', message: 'Setting up modules' }, { id: 'app', message: 'Preparing app' }, { id: 'types', message: 'Generating types' }, - { id: 'app (client)', message: 'Building app (client)' }, - { id: 'app (server)', message: 'Building app (server)' }, - { id: 'server (nitro)', message: 'Building server (nitro)' }, + { id: 'bundle (client)', message: 'Bundling client' }, + { id: 'bundle (server)', message: 'Bundling server' }, + { id: 'bundle (nitro)', message: 'Bundling nitro' }, ] const HOOK_PHASES: Record = { 'modules:before': 'modules', 'builder:generateApp': 'app', 'prepare:types': 'types', - 'build:before': 'app (client)', - 'nitro:build:before': 'server (nitro)', + 'build:before': 'bundle (client)', + 'nitro:build:before': 'bundle (nitro)', } /** Nitro builds on its own hooks, which Nuxt's never see. */ @@ -34,7 +34,7 @@ const NITRO_INIT_HOOK = 'nitro:init' * project is the longest silence of the build. */ const NITRO_MESSAGES: Record = { - 'rollup:before': 'Bundling server (nitro)', + 'rollup:before': 'Bundling nitro', 'prerender:routes': 'Prerendering routes', } @@ -136,7 +136,7 @@ export class BuildProgress extends PhaseTimeline { } if (name === 'webpack:compile') { const ctx = args?.[0] as { name?: string } | undefined - this.setPhase(ctx?.name === 'server' ? 'app (server)' : 'app (client)') + this.setPhase(ctx?.name === 'server' ? 'bundle (server)' : 'bundle (client)') } else if (name === NITRO_INIT_HOOK) { this.#attachNitro((args?.[0] as { hooks?: HookableLike } | undefined)?.hooks) @@ -156,11 +156,11 @@ export class BuildProgress extends PhaseTimeline { }, buildStart(this: { environment?: { name: string, config?: { consumer?: string } } }) { if (this.environment?.name === NITRO_ENVIRONMENT) { - setPhase('server (nitro)') + setPhase('bundle (nitro)') return } const consumer = this.environment?.config?.consumer ?? (ssr ? 'server' : 'client') - setPhase(consumer === 'server' ? 'app (server)' : 'app (client)') + setPhase(consumer === 'server' ? 'bundle (server)' : 'bundle (client)') }, } } @@ -169,7 +169,7 @@ export class BuildProgress extends PhaseTimeline { hooks?.beforeEach?.(({ name, args }) => { // Nitro's hooks also run while Nuxt is still bundling the app, and those // are not what the build is waiting on. - if (BUILD_PHASES[this.index]!.id !== 'server (nitro)') { + if (BUILD_PHASES[this.index]!.id !== 'bundle (nitro)') { return } const message = NITRO_MESSAGES[name] diff --git a/packages/nuxt-cli/test/unit/build-progress.spec.ts b/packages/nuxt-cli/test/unit/build-progress.spec.ts index f2d26ef57..901b150b0 100644 --- a/packages/nuxt-cli/test/unit/build-progress.spec.ts +++ b/packages/nuxt-cli/test/unit/build-progress.spec.ts @@ -74,11 +74,11 @@ describe('build progress', () => { 'Setting up modules', 'Preparing app', 'Generating types', - 'Building app (client)', - 'Building app (server)', - 'Building server (nitro)', + 'Bundling client', + 'Bundling server', + 'Bundling nitro', ]) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'app (client)', 'app (server)', 'server (nitro)']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'bundle (client)', 'bundle (server)', 'bundle (nitro)']) }) it('should split the bundle phase when a single config builds both environments', () => { @@ -93,15 +93,15 @@ describe('build progress', () => { stub.extendVite(config) const plugins = stub.extendVite(config) expect(plugins).toHaveLength(1) - expect(seen.at(-1)).toBe('Building app (client)') + expect(seen.at(-1)).toBe('Bundling client') plugins[0]!.configResolved({ build: {} }) plugins[0]!.buildStart.call({ environment: { config: { consumer: 'client' } } }) plugins[0]!.buildStart.call({ environment: { config: { consumer: 'server' } } }) progress.finish() - expect(seen).toEqual(['Loading Nuxt config', 'Building app (client)', 'Building app (server)']) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'app (client)', 'app (server)']) + expect(seen).toEqual(['Loading Nuxt config', 'Bundling client', 'Bundling server']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'bundle (client)', 'bundle (server)']) }) it('should name what the Nitro phase is doing', () => { @@ -118,7 +118,7 @@ describe('build progress', () => { stub.callNitro('prerender:route', { route: '/about' }) stub.callNitro('prerender:generate', { route: '/blog' }) - expect(seen).toEqual(['Loading Nuxt config', 'Building server (nitro)', 'Bundling server (nitro)', 'Prerendering /about', 'Prerendering /blog (1 done)']) + expect(seen).toEqual(['Loading Nuxt config', 'Bundling nitro', 'Prerendering /about', 'Prerendering /blog (1 done)']) }) it('should keep phase durations after the build is finished', () => { From 109519079d7bc4dea587b06aced3b6c15c444645 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Tue, 10 Nov 2026 11:40:26 +0000 Subject: [PATCH 10/38] feat(build,dev): label the total time on the progress line MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The progress line showed the phase's time and the command's next to each other with nothing to tell them apart. The second now reads 'total', as in 'Bundling nitro 2.44s · total 4.98s'. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/phase-reporter.ts | 2 +- packages/nuxt-cli/test/unit/phase-reporter.spec.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/nuxt-cli/src/utils/phase-reporter.ts b/packages/nuxt-cli/src/utils/phase-reporter.ts index 59583fb7e..d944119f8 100644 --- a/packages/nuxt-cli/src/utils/phase-reporter.ts +++ b/packages/nuxt-cli/src/utils/phase-reporter.ts @@ -37,7 +37,7 @@ function formatElapsed(snapshot: ProgressSnapshot, drift: number): string { const total = snapshot.elapsed + drift const phase = snapshot.phaseElapsed + drift return total - phase >= PHASE_ELAPSED_THRESHOLD - ? `${formatDuration(phase)} \u00B7 ${formatDuration(total)}` + ? `${formatDuration(phase)} \u00B7 total ${formatDuration(total)}` : formatDuration(total) } diff --git a/packages/nuxt-cli/test/unit/phase-reporter.spec.ts b/packages/nuxt-cli/test/unit/phase-reporter.spec.ts index 6c28f3c5a..aa9bb90e2 100644 --- a/packages/nuxt-cli/test/unit/phase-reporter.spec.ts +++ b/packages/nuxt-cli/test/unit/phase-reporter.spec.ts @@ -70,7 +70,7 @@ describe('phase reporter', () => { startup.update(snapshot({ phase: 'types', message: 'Generating types', index: 3, elapsed: 41_000, phaseElapsed: 33_000 })) }) - expect(screen(renderer)).toMatch(/^. Generating types 33\.0s \u00B7 41\.0s$/) + expect(screen(renderer)).toMatch(/^. Generating types 33\.0s \u00B7 total 41\.0s$/) }) it('should redraw only the spinner while the rest of the line is unchanged', () => { @@ -173,7 +173,7 @@ describe('phase reporter', () => { await waitForOutput('Generating server types') }) - expect(screen(renderer)).toContain('Generating server types (33.0s \u00B7 41.0s)') + expect(screen(renderer)).toContain('Generating server types (33.0s \u00B7 total 41.0s)') }) it('should leave foreign output intact', async () => { From 9109279d34c2bfd03166c37beead8fe4f1661c98 Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Tue, 10 Nov 2026 11:45:47 +0000 Subject: [PATCH 11/38] [autofix.ci] apply automated fixes --- capture/output/nuxt-dev-plain-restart.svg | 44 +++++++++++------------ capture/output/nuxt-dev-plain-restart.txt | 12 +++---- capture/output/nuxt-dev-plain-static.svg | 2 +- capture/output/nuxt-dev-plain-static.txt | 12 +++---- capture/output/nuxt-dev-plain.svg | 38 +++++++++----------- capture/output/nuxt-dev-plain.txt | 12 +++---- 6 files changed, 57 insertions(+), 63 deletions(-) diff --git a/capture/output/nuxt-dev-plain-restart.svg b/capture/output/nuxt-dev-plain-restart.svg index 6a74bb6a0..42e9f1b2e 100644 --- a/capture/output/nuxt-dev-plain-restart.svg +++ b/capture/output/nuxt-dev-plain-restart.svg @@ -16,28 +16,26 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (plain output, restart on config change) - -⠙ Starting Nuxt... 0.0ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose⠸ Setting up modules 0.0ms · 147ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠴ Preparing app 0.0ms · 297ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠦ Preparing app 181ms · 478ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠏ Generating types 7.0ms · 650ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠋ Generating types 98ms · 741ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠹ Bundling app 2.0ms · 908ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠴ Building server 12ms · 1.10s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠦ Building server 92ms · 1.18s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠧ Building server 173ms · 1.26s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠇ Building server 276ms · 1.36s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠋ Building server 437ms · 1.52s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠙ Building server 517ms · 1.60s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠹ Building server 601ms · 1.69s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠼ Building server 761ms · 1.85s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms✔ Nuxt Nitro server built in 1021ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 147ms · modules 150ms · app 346ms · types 263ms · bundle 185ms · server 1.12spressh + enterto see available shortcuts -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms✔ Nuxt Nitro server built in 1021ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 147ms · modules 150ms · app 346ms · types 263ms · bundle 185ms · server 1.12spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated -➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms✔ Nuxt Nitro server built in 1021ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 147ms · modules 150ms · app 346ms · types 263ms · bundle 185ms · server 1.12spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 24ms -➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms✔ Nuxt Nitro server built in 1021ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 147ms · modules 150ms · app 346ms · types 263ms · bundle 185ms · server 1.12spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 24ms✔ Nuxt Nitro server built in 755ms nitro -⠸ Bundling app 117ms · 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms✔ Nuxt Nitro server built in 1021ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 147ms · modules 150ms · app 346ms · types 263ms · bundle 185ms · server 1.12spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 24ms✔ Nuxt Nitro server built in 755ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2) -│◆ Ready in 2.21s →http://localhost:3000/│config 147ms · modules 150ms · app 346ms · types 263ms · bundle 185ms · server 1.12spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 24ms✔ Nuxt Nitro server built in 755ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 18ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 13ms -◆ Ready in 2.21s →http://localhost:3000/│config 147ms · modules 150ms · app 346ms · types 263ms · bundle 185ms · server 1.12spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 24ms✔ Nuxt Nitro server built in 755ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 18ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 13ms✔ Nuxt Nitro server built in 665ms nitro + +⠙ Starting Nuxt... 0.0ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose⠸ Setting up modules 0.0ms · total 121ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠴ Preparing app 0.0ms · total 235ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠦ Preparing app 144ms · total 379ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠏ Generating types 38ms · total 554ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠙ Bundling app 2.0ms · total 726ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠼ Building server 40ms · total 900ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠴ Building server 131ms · total 991ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠦ Building server 226ms · total 1.08s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠧ Building server 311ms · total 1.17s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠇ Building server 392ms · total 1.25s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠏ Building server 515ms · total 1.37s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠋ Building server 597ms · total 1.45s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcuts +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated +➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms +➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms✔ Nuxt Nitro server built in 653ms nitro + WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms✔ Nuxt Nitro server built in 653ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed +│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms✔ Nuxt Nitro server built in 653ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 15ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 11ms +◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms✔ Nuxt Nitro server built in 653ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 15ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 11ms✔ Nuxt Nitro server built in 573ms nitro diff --git a/capture/output/nuxt-dev-plain-restart.txt b/capture/output/nuxt-dev-plain-restart.txt index bc491c37b..2d2b15f9c 100644 --- a/capture/output/nuxt-dev-plain-restart.txt +++ b/capture/output/nuxt-dev-plain-restart.txt @@ -1,4 +1,4 @@ -styles: b9481c350ba0bd29 +styles: 8420d148a08cc212 devtools updated press h + enter to see available shortcuts ➜ DevTools: press Shift + Alt + D in the browser (x.y.z) @@ -15,9 +15,9 @@ styles: b9481c350ba0bd29 ✔ Nuxt Nitro server built in 42 ms nitro ✔ Vite client built in 42 ms ✔ Vite server built in 42 ms -⠋ Building server 42 ms -⠋ Bundling app 42 ms -⠋ Generating types 42 ms -⠋ Preparing app 42 ms -⠋ Setting up modules 42 ms +⠋ Building server 42 ms · total 42 ms +⠋ Bundling app 42 ms · total 42 ms +⠋ Generating types 42 ms · total 42 ms +⠋ Preparing app 42 ms · total 42 ms +⠋ Setting up modules 42 ms · total 42 ms ⠋ Starting Nuxt... 42 ms diff --git a/capture/output/nuxt-dev-plain-static.svg b/capture/output/nuxt-dev-plain-static.svg index 2a3a5a256..bd8eb6a35 100644 --- a/capture/output/nuxt-dev-plain-static.svg +++ b/capture/output/nuxt-dev-plain-static.svg @@ -16,6 +16,6 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (plain output, ready) -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 111ms · 1.04s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 44ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 13ms✔ Nuxt Nitro server built in 1075ms nitro│◆ Ready in 2.25s →http://localhost:3000/│config 155ms · modules 156ms · app 346ms · types 274ms · bundle 165ms · server 1.16spressh + enterto see available shortcuts +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 91ms · total 815ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 11ms✔ Nuxt Nitro server built in 866ms nitro│◆ Ready in 1.79s →http://localhost:3000/│config 122ms · modules 116ms · app 278ms · types 208ms · bundle 133ms · server 942mspressh + enterto see available shortcuts diff --git a/capture/output/nuxt-dev-plain-static.txt b/capture/output/nuxt-dev-plain-static.txt index 604022800..40b764d8c 100644 --- a/capture/output/nuxt-dev-plain-static.txt +++ b/capture/output/nuxt-dev-plain-static.txt @@ -1,4 +1,4 @@ -styles: 0b16b2e9f0d61733 +styles: 7e3af84ab72118eb press h + enter to see available shortcuts ➜ DevTools: press Shift + Alt + D in the browser (x.y.z) ➜ Local: http://localhost:3000/ @@ -12,9 +12,9 @@ styles: 0b16b2e9f0d61733 ✔ Nuxt Nitro server built in 42 ms nitro ✔ Vite client built in 42 ms ✔ Vite server built in 42 ms -⠋ Building server 42 ms -⠋ Bundling app 42 ms -⠋ Generating types 42 ms -⠋ Preparing app 42 ms -⠋ Setting up modules 42 ms +⠋ Building server 42 ms · total 42 ms +⠋ Bundling app 42 ms · total 42 ms +⠋ Generating types 42 ms · total 42 ms +⠋ Preparing app 42 ms · total 42 ms +⠋ Setting up modules 42 ms · total 42 ms ⠋ Starting Nuxt... 42 ms diff --git a/capture/output/nuxt-dev-plain.svg b/capture/output/nuxt-dev-plain.svg index 1c08628c3..945417354 100644 --- a/capture/output/nuxt-dev-plain.svg +++ b/capture/output/nuxt-dev-plain.svg @@ -16,26 +16,22 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (plain output) - -⠙ Starting Nuxt... 0.0ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose⠸ Setting up modules 0.0ms · 156ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠴ Preparing app 0.0ms · 315ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠦ Preparing app 180ms · 495ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠏ Generating types 5.0ms · 667ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠋ Generating types 108ms · 770ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠹ Bundling app 2.0ms · 937ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠴ Building server 0.0ms · 1.19s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠦ Building server 30ms · 1.22s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠧ Building server 112ms · 1.30s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠇ Building server 197ms · 1.39s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠏ Building server 279ms · 1.47s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠋ Building server 371ms · 1.56s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠙ Building server 456ms · 1.65s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠹ Building server 536ms · 1.73s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠸ Building server 617ms · 1.81s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠼ Building server 700ms · 1.89s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms⠦ Building server 863ms · 2.06s -│●Nuxt 4.6.1 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.43)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.2)⠸ Bundling app 120ms · 1.05s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 52ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 24ms✔ Nuxt Nitro server built in 1085ms nitro│◆ Ready in 2.43s →http://localhost:3000/│config 156ms · modules 159ms · app 347ms · types 273ms · bundle 262ms · server 1.24spressh + enterto see available shortcuts + +⠙ Starting Nuxt... 0.0ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose⠸ Setting up modules 0.0ms · total 122ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠴ Preparing app 0.0ms · total 238ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠦ Preparing app 145ms · total 383ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠇ Generating types 0.0ms · total 516ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠏ Generating types 42ms · total 558ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠙ Bundling app 2.0ms · total 722ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠼ Building server 0.0ms · total 914ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠴ Building server 90ms · total 1.00s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠦ Building server 183ms · total 1.09s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠧ Building server 270ms · total 1.18s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠇ Building server 353ms · total 1.26s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠏ Building server 433ms · total 1.34s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠙ Building server 618ms · total 1.53s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms✔ Nuxt Nitro server built in 857ms nitro│◆ Ready in 1.89s →http://localhost:3000/│config 122ms · modules 116ms · app 278ms · types 204ms · bundle 194ms · server 983mspressh + enterto see available shortcuts diff --git a/capture/output/nuxt-dev-plain.txt b/capture/output/nuxt-dev-plain.txt index 406c17709..c3e3e9ef4 100644 --- a/capture/output/nuxt-dev-plain.txt +++ b/capture/output/nuxt-dev-plain.txt @@ -1,4 +1,4 @@ -styles: d2449122d4dda2b2 +styles: 8fd08b59c97840b9 press h + enter to see available shortcuts ➜ DevTools: press Shift + Alt + D in the browser (x.y.z) ➜ Local: http://localhost:3000/ @@ -12,9 +12,9 @@ styles: d2449122d4dda2b2 ✔ Nuxt Nitro server built in 42 ms nitro ✔ Vite client built in 42 ms ✔ Vite server built in 42 ms -⠋ Building server 42 ms -⠋ Bundling app 42 ms -⠋ Generating types 42 ms -⠋ Preparing app 42 ms -⠋ Setting up modules 42 ms +⠋ Building server 42 ms · total 42 ms +⠋ Bundling app 42 ms · total 42 ms +⠋ Generating types 42 ms · total 42 ms +⠋ Preparing app 42 ms · total 42 ms +⠋ Setting up modules 42 ms · total 42 ms ⠋ Starting Nuxt... 42 ms From ce0cf75872a6e66e35c3d4594a8da8f07ccba2ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 10:32:28 +0000 Subject: [PATCH 12/38] refactor(build): one Vite plugin and the phase timings for the server summary server-output and build-progress each added a Vite plugin to follow which environment was building, and server-output kept its own clock for the summary. One plugin now reports each environment to the progress, which gains a prerender phase, and the summary reads its times from the phase timings. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 4 +- packages/nuxt-cli/src/utils/build-progress.ts | 123 +++++++----------- packages/nuxt-cli/src/utils/server-output.ts | 82 +++++------- .../nuxt-cli/test/unit/build-progress.spec.ts | 80 ++++++------ .../test/unit/utils/server-output.spec.ts | 35 +++-- 5 files changed, 145 insertions(+), 179 deletions(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 8870b03a7..21b7dc1c7 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -107,7 +107,7 @@ export default defineCommand({ }) progress.attachNuxt(nuxt) - const serverOutput = quietServerOutput(nuxt) + const serverOutput = quietServerOutput(nuxt, { onEnvironment: environment => progress.enterEnvironment(environment) }) showBanner(nuxt) await nuxt.ready() @@ -146,7 +146,7 @@ export default defineCommand({ stopReporting() progress.finish() - const serverSummary = serverOutput.summary() + const serverSummary = serverOutput.summary(progress.timings) if (serverSummary) { logger.success(serverSummary) } diff --git a/packages/nuxt-cli/src/utils/build-progress.ts b/packages/nuxt-cli/src/utils/build-progress.ts index 537134704..8ada50b88 100644 --- a/packages/nuxt-cli/src/utils/build-progress.ts +++ b/packages/nuxt-cli/src/utils/build-progress.ts @@ -14,6 +14,7 @@ const BUILD_PHASES: readonly Phase[] = [ { id: 'types', message: 'Generating types' }, { id: 'bundle (client)', message: 'Bundling client' }, { id: 'bundle (server)', message: 'Bundling server' }, + { id: 'prerender', message: 'Prerendering routes' }, { id: 'bundle (nitro)', message: 'Bundling nitro' }, ] @@ -22,40 +23,32 @@ const HOOK_PHASES: Record = { 'builder:generateApp': 'app', 'prepare:types': 'types', 'build:before': 'bundle (client)', - 'nitro:build:before': 'bundle (nitro)', } /** Nitro builds on its own hooks, which Nuxt's never see. */ const NITRO_INIT_HOOK = 'nitro:init' - -/** - * Nitro's own hooks, relabelled. Without these the Nitro phase says nothing - * between the bundle starting and the output being written, which on a large - * project is the longest silence of the build. - */ -const NITRO_MESSAGES: Record = { - 'rollup:before': 'Bundling nitro', - 'prerender:routes': 'Prerendering routes', -} +const NITRO_BUILD_HOOK = 'nitro:build:before' const PRERENDER_HOOK = 'prerender:generate' const PRERENDERED_HOOK = 'prerender:route' +/** The Vite environment Nitro 3 builds the server in. */ +const NITRO_ENVIRONMENT = 'nitro' + interface HookableLike { beforeEach?: (fn: (event: { name: string, args?: unknown[] }) => void) => void } interface NuxtLike { options?: { experimental?: { nitroViteEnvironment?: boolean } } - hook?: (name: 'vite:extendConfig', fn: (config: { plugins?: unknown[] }) => void) => unknown hooks?: HookableLike } -/** Names the Vite plugin that reports which environment is being built, so it is added once per config. */ -const VITE_PLUGIN_NAME = 'nuxi:build-progress' - -/** The Vite environment Nitro 3 builds the server in. */ -const NITRO_ENVIRONMENT = 'nitro' +/** A Vite environment as it starts building. */ +export interface BuildEnvironment { + name?: string + consumer?: string +} /** * Tracks how far a production build has got, so the same transient phase line @@ -109,82 +102,64 @@ export class BuildProgress extends PhaseTimeline { } } + /** + * Move to the bundle phase of a Vite environment that has started building. + * Vite resolves every config before it bundles anything, and with the + * environment API one config builds them all, so only the build itself knows + * which one it has reached. + */ + enterEnvironment({ name, consumer }: BuildEnvironment): void { + if (name === NITRO_ENVIRONMENT) { + this.setPhase('bundle (nitro)') + return + } + this.setPhase(consumer === 'server' ? 'bundle (server)' : 'bundle (client)') + } + /** * Derive phases from the hooks Nuxt and Nitro call, so the timeline follows * the project's own build rather than a schedule guessed by the CLI. */ attachNuxt(nuxt: NuxtLike): void { - // Vite configs resolve before anything is bundled, and with the environment - // API (which a server builder such as `@nuxt/vite-server` can switch on during - // setup) one config builds both environments. Only the build itself knows - // which environment it has reached. - nuxt.hook?.('vite:extendConfig', (config) => { - if (config.plugins && !config.plugins.some(plugin => (plugin as { name?: string } | null)?.name === VITE_PLUGIN_NAME)) { - config.plugins.push(this.#vitePlugin()) - } - }) + let nitroBuilding = false nuxt.hooks?.beforeEach?.(({ name, args }) => { const phase = HOOK_PHASES[name] - // Nitro 3 can build as a Vite environment, after the app, and is then - // reported by the Vite plugin when its environment starts. - if (phase && !(name === 'nitro:build:before' && nuxt.options?.experimental?.nitroViteEnvironment)) { + if (phase) { this.setPhase(phase) - return } - if (phase) { - return + else if (name === NITRO_BUILD_HOOK) { + nitroBuilding = true } - if (name === 'webpack:compile') { + else if (name === 'webpack:compile') { const ctx = args?.[0] as { name?: string } | undefined this.setPhase(ctx?.name === 'server' ? 'bundle (server)' : 'bundle (client)') } else if (name === NITRO_INIT_HOOK) { - this.#attachNitro((args?.[0] as { hooks?: HookableLike } | undefined)?.hooks) + // Nitro's hooks also run while Nuxt is still bundling the app, and those + // are not what the build is waiting on. + const hooks = (args?.[0] as { hooks?: HookableLike } | undefined)?.hooks + hooks?.beforeEach?.(event => nitroBuilding && this.#onNitroHook(event, !!nuxt.options?.experimental?.nitroViteEnvironment)) } }) } - #vitePlugin() { - let ssr = false - const setPhase = (id: string) => this.setPhase(id) - return { - name: VITE_PLUGIN_NAME, - apply: 'build' as const, - // Before Vite 6 each environment has a config of its own. - configResolved(config: { build?: { ssr?: unknown } }) { - ssr = !!config.build?.ssr - }, - buildStart(this: { environment?: { name: string, config?: { consumer?: string } } }) { - if (this.environment?.name === NITRO_ENVIRONMENT) { - setPhase('bundle (nitro)') - return - } - const consumer = this.environment?.config?.consumer ?? (ssr ? 'server' : 'client') - setPhase(consumer === 'server' ? 'bundle (server)' : 'bundle (client)') - }, + #onNitroHook({ name, args }: { name: string, args?: unknown[] }, viteEnvironment: boolean): void { + if (name === 'prerender:init') { + this.setPhase('prerender') } - } - - #attachNitro(hooks: HookableLike | undefined): void { - hooks?.beforeEach?.(({ name, args }) => { - // Nitro's hooks also run while Nuxt is still bundling the app, and those - // are not what the build is waiting on. - if (BUILD_PHASES[this.index]!.id !== 'bundle (nitro)') { - return - } - const message = NITRO_MESSAGES[name] - if (message) { - this.setMessage(message) - } - else if (name === PRERENDER_HOOK) { - const route = (args?.[0] as { route?: string } | undefined)?.route - if (route) { - this.setMessage(this.#prerendered ? `Prerendering ${route} (${this.#prerendered} done)` : `Prerendering ${route}`) - } - } - else if (name === PRERENDERED_HOOK) { - this.#prerendered++ + // Nitro 2 bundles with Rollup; Nitro 3 as a Vite environment, reported + // through `enterEnvironment`, and runs its Rollup hooks early. + else if (name === 'rollup:before' && !viteEnvironment) { + this.setPhase('bundle (nitro)') + } + else if (name === PRERENDER_HOOK && BUILD_PHASES[this.index]!.id === 'prerender') { + const route = (args?.[0] as { route?: string } | undefined)?.route + if (route) { + this.setMessage(this.#prerendered ? `Prerendering ${route} (${this.#prerendered} done)` : `Prerendering ${route}`) } - }) + } + else if (name === PRERENDERED_HOOK) { + this.#prerendered++ + } } } diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index db9fcc0b5..2ace1702e 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -1,5 +1,7 @@ import type { Nuxt } from '@nuxt/schema' import type { Nitro, PrerenderRoute } from 'nitropack' +import type { BuildEnvironment } from './build-progress' +import type { PhaseTiming } from './progress-snapshot' import { readdir, stat } from 'node:fs/promises' import process from 'node:process' @@ -13,9 +15,6 @@ import { logger } from './logger' /** Nitro's `warn` level: warnings and errors still print, progress and file trees do not. */ const NITRO_QUIET_LOG_LEVEL = 1 -/** The Vite environment Nitro 3 builds the server in. */ -const NITRO_ENVIRONMENT = 'nitro' - const VITE_PLUGIN_NAME = 'nuxi:server-output' /** The line Vite opens each environment's build with, e.g. `vite v8.3.5 building ssr environment for production...`. */ @@ -25,8 +24,13 @@ const ENVIRONMENT_BUILD_RE = /building (\S+) environment for/ const SOURCE_MAP_RE = /\.map(?:\.json)?$/ export interface ServerOutputReport { - /** The one-line summary of the server build, or nothing for a static-only build. */ - summary: () => string | undefined + /** The summary of the server build, from the build's phase timings, or nothing for a static-only build. */ + summary: (timings: PhaseTiming[]) => string | undefined +} + +interface ServerOutputOptions { + /** Called as each Vite environment starts building. */ + onEnvironment?: (environment: BuildEnvironment) => void } interface ViteLogger { @@ -39,6 +43,7 @@ interface ResolvedViteConfig { } interface ViteBuildContext { + /** Absent before Vite 6, where each environment has a config of its own. */ environment?: { name: string, config: { consumer?: string } } } @@ -59,21 +64,15 @@ interface MaybeServerBuild { * Nothing changes at `--log-level verbose`, or when the project sets a log * level for Nitro or Vite itself. */ -export function quietServerOutput(nuxt: Nuxt): ServerOutputReport { +export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}): ServerOutputReport { const quiet = nuxt.options.logLevel !== 'verbose' let usesNitro = false - let started: number | undefined - let duration: number | undefined let size: number | undefined - let prerender: { count: number, duration: number } | undefined + let prerendered = 0 let deploy: string | undefined let isStatic = false - const finish = async (dir: string | undefined) => { - if (started === undefined || duration !== undefined) { - return - } - duration = Date.now() - started + const measure = async (dir: string | undefined) => { size = dir ? await directorySize(dir).catch(() => undefined) : undefined } @@ -106,10 +105,12 @@ export function quietServerOutput(nuxt: Nuxt): ServerOutputReport { function createVitePlugin() { const servers = new Set() let muted = false + let ssr = false return { name: VITE_PLUGIN_NAME, apply: 'build' as const, - configResolved(config: ResolvedViteConfig) { + configResolved(config: ResolvedViteConfig & { build?: { ssr?: unknown } }) { + ssr = !!config.build?.ssr for (const [name, environment] of Object.entries(config.environments ?? {})) { if (environment.consumer === 'server') { servers.add(name) @@ -133,80 +134,55 @@ export function quietServerOutput(nuxt: Nuxt): ServerOutputReport { } }, buildStart(this: ViteBuildContext) { - const environment = this.environment - if (!environment) { - return - } - muted = environment.config.consumer === 'server' && quietVite - // The Vite environment that writes the server output, where there is one. - // Nitro 3 also runs its Rollup hooks before the app is bundled, so its - // environment starting is what marks the server build. - if (environment.name === NITRO_ENVIRONMENT) { - started = Date.now() - } - else if (!usesNitro && environment.config.consumer === 'server') { - started ??= Date.now() - } + const consumer = this.environment?.config.consumer ?? (ssr ? 'server' : 'client') + muted = consumer === 'server' && quietVite + options.onEnvironment?.({ name: this.environment?.name, consumer }) }, } } - let buildStarted = Date.now() - nuxt.hook('nitro:build:before', () => { - buildStarted = Date.now() - }) - let prerenderStarted: number | undefined - // Without Nitro the Vite server build is the whole server output. nuxt.hook('build:done', async () => { if (!usesNitro) { const dir = (nuxt as unknown as MaybeServerBuild).serverBuild?.output.dir() - await finish(dir ? join(dir, 'server') : undefined) + await measure(dir ? join(dir, 'server') : undefined) } }) nuxt.hook('nitro:init', (nitro) => { usesNitro = true - let prerendered = 0 - // Nitro 3 prerenders after the app is bundled, so the clock starts with the prerenderer. - nitro.hooks.hook('prerender:init', () => { - prerenderStarted = Date.now() - }) nitro.hooks.hook('prerender:route', (route) => { if (!route.error) { prerendered++ } }) nitro.hooks.hook('prerender:done', ({ failedRoutes }) => { - prerender = { count: prerendered, duration: Date.now() - (prerenderStarted ?? buildStarted) } // Nitro lists these at its `log` level, which the quiet build drops. if (failedRoutes.length && quiet) { logger.error(`Failed to prerender ${failedRoutes.length} route${failedRoutes.length === 1 ? '' : 's'}:\n${ failedRoutes.map(formatFailedRoute).join('\n')}`) } }) - // Nitro 2 bundles with its own Rollup build. - nitro.hooks.hook('rollup:before', () => { - started ??= Date.now() - }) nitro.hooks.hook('compiled', async () => { isStatic = !!nitro.options.static - started ??= buildStarted deploy = nitro.options.commands?.deploy ? resolveDeployCommand(nitro) : undefined - await finish(nitro.options.output.serverDir) + await measure(nitro.options.output.serverDir) }) }) return { - summary() { + summary(timings) { const lines: string[] = [] - if (prerender && prerender.count) { - lines.push(`Prerendered ${prerender.count} route${prerender.count === 1 ? '' : 's'} in ${formatDuration(prerender.duration)}`) + const prerender = timings.find(timing => timing.phase === 'prerender') + if (prerender && prerendered) { + lines.push(`Prerendered ${prerendered} route${prerendered === 1 ? '' : 's'} in ${formatDuration(prerender.duration)}`) } + // Without Nitro, the Vite server bundle is the server output. + const server = timings.find(timing => timing.phase === (usesNitro ? 'bundle (nitro)' : 'bundle (server)')) // No size means nothing was written, as in a static build. - if (!isStatic && duration !== undefined && size !== undefined) { + if (!isStatic && server && size !== undefined) { const builder = usesNitro ? 'nitro' : (nuxt as unknown as MaybeServerBuild).serverBuild?.name || 'server' - lines.push(`Server (${builder}) built in ${formatDuration(duration)}${size === undefined ? '' : styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) + lines.push(`Server (${builder}) built in ${formatDuration(server.duration)}${styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) lines.push(styleText('dim', `Preview: ${styleText('cyan', 'npx nuxt preview')}`)) if (deploy) { lines.push(styleText('dim', `Deploy: ${styleText('cyan', deploy)}`)) diff --git a/packages/nuxt-cli/test/unit/build-progress.spec.ts b/packages/nuxt-cli/test/unit/build-progress.spec.ts index 901b150b0..ce6b1ef66 100644 --- a/packages/nuxt-cli/test/unit/build-progress.spec.ts +++ b/packages/nuxt-cli/test/unit/build-progress.spec.ts @@ -6,19 +6,12 @@ import { BuildProgress } from '../../src/utils/build-progress' type HookHandler = (event: { name: string, args?: unknown[] }) => void -interface VitePlugin { - name: string - configResolved: (config: { build?: { ssr?: unknown } }) => void - buildStart: (this: { environment?: { config: { consumer: string } } }) => void -} - -function nuxtStub() { +function nuxtStub(options: { nitroViteEnvironment?: boolean } = {}) { const handlers: HookHandler[] = [] const nitroHandlers: HookHandler[] = [] - const extendConfig: Array<(config: { plugins: unknown[] }) => void> = [] return { nuxt: { - hook: (_name: 'vite:extendConfig', fn: (config: { plugins: unknown[] }) => void) => void extendConfig.push(fn), + options: { experimental: { nitroViteEnvironment: options.nitroViteEnvironment } }, hooks: { beforeEach: (fn: HookHandler) => void handlers.push(fn) }, }, call(name: string, ...args: unknown[]) { @@ -26,13 +19,6 @@ function nuxtStub() { handler({ name, args }) } }, - /** Run `vite:extendConfig` on a config and return the plugins the CLI added to it. */ - extendVite(config: { plugins: unknown[] }): VitePlugin[] { - for (const fn of extendConfig) { - fn(config) - } - return config.plugins as VitePlugin[] - }, nitro: { hooks: { beforeEach: (fn: HookHandler) => void nitroHandlers.push(fn) } }, callNitro(name: string, ...args: unknown[]) { for (const handler of nitroHandlers) { @@ -53,20 +39,18 @@ describe('build progress', () => { const progress = new BuildProgress() const stub = nuxtStub() progress.attachNuxt(stub.nuxt) + stub.call('nitro:init', stub.nitro) const seen = messages(progress) stub.call('modules:before') stub.call('builder:generateApp') stub.call('prepare:types') stub.call('build:before') - // Without the environment API, client and server each have a config and a build. - const [client] = stub.extendVite({ plugins: [] }) - const [server] = stub.extendVite({ plugins: [] }) - client!.configResolved({ build: {} }) - server!.configResolved({ build: { ssr: true } }) - client!.buildStart.call({}) - server!.buildStart.call({}) + progress.enterEnvironment({ name: 'client', consumer: 'client' }) + progress.enterEnvironment({ name: 'ssr', consumer: 'server' }) stub.call('nitro:build:before', {}) + stub.callNitro('prerender:init') + stub.callNitro('rollup:before') progress.finish() expect(seen).toEqual([ @@ -76,49 +60,61 @@ describe('build progress', () => { 'Generating types', 'Bundling client', 'Bundling server', + 'Prerendering routes', 'Bundling nitro', ]) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'bundle (client)', 'bundle (server)', 'bundle (nitro)']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules', 'app', 'types', 'bundle (client)', 'bundle (server)', 'prerender', 'bundle (nitro)']) }) - it('should split the bundle phase when a single config builds both environments', () => { + it('should ignore Nitro\'s hooks until Nuxt starts the Nitro build', () => { const progress = new BuildProgress() const stub = nuxtStub() progress.attachNuxt(stub.nuxt) + stub.call('nitro:init', stub.nitro) const seen = messages(progress) + // Nitro runs its Rollup hooks while Nuxt is still bundling the app. stub.call('build:before') - // The environment API extends one shared config once per environment, up front. - const config = { plugins: [] } - stub.extendVite(config) - const plugins = stub.extendVite(config) - expect(plugins).toHaveLength(1) - expect(seen.at(-1)).toBe('Bundling client') - - plugins[0]!.configResolved({ build: {} }) - plugins[0]!.buildStart.call({ environment: { config: { consumer: 'client' } } }) - plugins[0]!.buildStart.call({ environment: { config: { consumer: 'server' } } }) - progress.finish() + stub.callNitro('rollup:before') + progress.enterEnvironment({ name: 'ssr', consumer: 'server' }) expect(seen).toEqual(['Loading Nuxt config', 'Bundling client', 'Bundling server']) - expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'bundle (client)', 'bundle (server)']) }) - it('should name what the Nitro phase is doing', () => { + it('should take the Nitro phase from its Vite environment when Nitro builds with Vite', () => { const progress = new BuildProgress() - const stub = nuxtStub() + const stub = nuxtStub({ nitroViteEnvironment: true }) progress.attachNuxt(stub.nuxt) stub.call('nitro:init', stub.nitro) const seen = messages(progress) - stub.callNitro('rollup:before') + // Nitro 3 starts its build before Vite bundles the app. stub.call('nitro:build:before', {}) stub.callNitro('rollup:before') + progress.enterEnvironment({ name: 'client', consumer: 'client' }) + progress.enterEnvironment({ name: 'ssr', consumer: 'server' }) + stub.callNitro('prerender:init') + progress.enterEnvironment({ name: 'nitro', consumer: 'server' }) + progress.finish() + + expect(seen).toEqual(['Loading Nuxt config', 'Bundling client', 'Bundling server', 'Prerendering routes', 'Bundling nitro']) + expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'bundle (client)', 'bundle (server)', 'prerender', 'bundle (nitro)']) + }) + + it('should count prerendered routes', () => { + const progress = new BuildProgress() + const stub = nuxtStub() + progress.attachNuxt(stub.nuxt) + stub.call('nitro:init', stub.nitro) + const seen = messages(progress) + + stub.call('nitro:build:before', {}) + stub.callNitro('prerender:init') stub.callNitro('prerender:generate', { route: '/about' }) stub.callNitro('prerender:route', { route: '/about' }) stub.callNitro('prerender:generate', { route: '/blog' }) - expect(seen).toEqual(['Loading Nuxt config', 'Bundling nitro', 'Prerendering /about', 'Prerendering /blog (1 done)']) + expect(seen).toEqual(['Loading Nuxt config', 'Prerendering routes', 'Prerendering /about', 'Prerendering /blog (1 done)']) }) it('should keep phase durations after the build is finished', () => { @@ -129,7 +125,7 @@ describe('build progress', () => { stub.call('modules:before') progress.finish() progress.finish() - stub.call('nitro:build:before', {}) + progress.enterEnvironment({ name: 'client', consumer: 'client' }) expect(progress.timings.map(timing => timing.phase)).toEqual(['config', 'modules']) expect(progress.snapshot.phase).toBe('modules') diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index ad66befcb..45eeb74f3 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -81,6 +81,21 @@ describe('quietServerOutput', () => { ]) }) + it('reports each Vite environment as it starts building, before Vite 6 too', async () => { + const { nuxt, hooks } = createNuxt() + const started: unknown[] = [] + quietServerOutput(nuxt as any, { onEnvironment: environment => void started.push(environment) }) + const { plugin } = await resolveVitePlugin(hooks) + plugin.buildStart.call({ environment: { name: 'nitro', config: { consumer: 'server' } } }) + + const legacy = { plugins: [] as any[] } + await hooks.call('vite:extendConfig', legacy, { isClient: false, isServer: true }) + legacy.plugins[0].configResolved({ logger: { info: () => {} }, build: { ssr: true } }) + legacy.plugins[0].buildStart.call({}) + + expect(started).toEqual([{ name: 'nitro', consumer: 'server' }, { name: undefined, consumer: 'server' }]) + }) + it('leaves log levels alone when verbose or set by the project', async () => { const verbose = createNuxt({ logLevel: 'verbose' }) quietServerOutput(verbose.nuxt as any) @@ -121,17 +136,20 @@ describe('quietServerOutput', () => { hooks: nitroHooks, } await hooks.call('nitro:init', nitro) - await hooks.call('nitro:build:before', nitro) await nitroHooks.call('prerender:route', { route: '/' }) await nitroHooks.call('prerender:route', { route: '/gone', error: { statusCode: 404 } }) await nitroHooks.call('prerender:done', { failedRoutes: [{ route: '/gone', error: { statusCode: 404, statusMessage: 'Not Found' } }] }) - await nitroHooks.call('rollup:before', nitro) await nitroHooks.call('compiled', nitro) - const lines = stripAnsi(report.summary()!).split('\n') - expect(lines[0]).toMatch(/^Prerendered 1 route in \S+$/) + const timings = [ + { phase: 'bundle (server)', message: '', duration: 300 }, + { phase: 'prerender', message: '', duration: 1200 }, + { phase: 'bundle (nitro)', message: '', duration: 2500 }, + ] + const lines = stripAnsi(report.summary(timings)!).split('\n') + expect(lines[0]).toBe('Prerendered 1 route in 1.20s') // Source maps are left out, as Nitro leaves them out of its own total. - expect(lines[1]).toMatch(/^Server \(nitro\) built in \S+ · 2\.50 kB$/) + expect(lines[1]).toBe('Server (nitro) built in 2.50s · 2.50 kB') expect(lines[2]).toBe('Preview: npx nuxt preview') expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 1 route:\n /gone (404 Not Found)') }) @@ -150,8 +168,9 @@ describe('quietServerOutput', () => { plugin.buildStart.call({ environment: { name: 'ssr', config: { consumer: 'server' } } }) await hooks.call('build:done') - expect(stripAnsi(report.summary()!).split('\n')).toEqual([ - expect.stringMatching(/^Server \(vite\) built in \S+ · 1\.20 kB$/), + const timings = [{ phase: 'bundle (client)', message: '', duration: 900 }, { phase: 'bundle (server)', message: '', duration: 400 }] + expect(stripAnsi(report.summary(timings)!).split('\n')).toEqual([ + 'Server (vite) built in 400ms · 1.20 kB', 'Preview: npx nuxt preview', ]) }) @@ -164,7 +183,7 @@ describe('quietServerOutput', () => { await hooks.call('nitro:init', nitro) await nitroHooks.call('compiled', nitro) - expect(report.summary()).toBeUndefined() + expect(report.summary([{ phase: 'bundle (nitro)', message: '', duration: 100 }])).toBeUndefined() }) }) From 31b35fa5b9ce501ca13b4d54a18eeb0aec6d962d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 10:52:59 +0000 Subject: [PATCH 13/38] fix(capture): pin labelled phase clocks in recorded timings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The progress line now reads '42 ms · total 42 ms' once a phase's clock and the total differ, which the timings scrub did not collapse, so a recording kept or dropped the second clock depending on machine speed. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- capture/lib/frames.spec.ts | 6 ++++++ capture/lib/scrub.ts | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/capture/lib/frames.spec.ts b/capture/lib/frames.spec.ts index b90bcb565..93a2cf78f 100644 --- a/capture/lib/frames.spec.ts +++ b/capture/lib/frames.spec.ts @@ -110,6 +110,12 @@ describe('scrubbing a right-aligned tag', () => { expect(result.styles).toHaveLength(result.line.length) }) + it.each(['⠋ Setting up modules 1.2s · total 3.4s', '⠋ Setting up modules 1.2s · 3.4s', '⠋ Setting up modules 3.4s'])('should pin a phase line however the clocks differed: %s', (line) => { + const styles = Array.from({ length: line.length }).fill(undefined) as never + + expect(scrubLine(line, styles, resolveRules(['timings'])).line).toBe('⠋ Setting up modules 42 ms') + }) + it('should leave a line without padding alone', () => { expect(scrub('42 ms').trimEnd()).not.toBe('') const plain = '✔ Vite client built in 1085 ms' diff --git a/capture/lib/scrub.ts b/capture/lib/scrub.ts index 67196ab38..e24eec22b 100644 --- a/capture/lib/scrub.ts +++ b/capture/lib/scrub.ts @@ -50,7 +50,7 @@ const RULES: Record = { { pattern: /\b\d+(?:\.\d+)?\s?s(?![a-z])/g, replacement: () => '42 ms' }, // A phase clock is only printed beside the total once they differ, so // the pair is a function of machine speed and carries nothing once pinned. - { pattern: /42 ms \u00B7 42 ms/g, replacement: () => '42 ms' }, + { pattern: /42 ms \u00B7 (?:total )?42 ms/g, replacement: () => '42 ms' }, ], }, versions: { From 2ab4a3590763451f09e1b8ac342fb014e4c0f450 Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Thu, 12 Nov 2026 10:55:23 +0000 Subject: [PATCH 14/38] [autofix.ci] apply automated fixes --- capture/output/nuxt-dev-plain-restart.svg | 45 ++++++++++++----------- capture/output/nuxt-dev-plain-restart.txt | 12 +++--- capture/output/nuxt-dev-plain-static.svg | 2 +- capture/output/nuxt-dev-plain-static.txt | 12 +++--- capture/output/nuxt-dev-plain.svg | 38 ++++++++++--------- capture/output/nuxt-dev-plain.txt | 12 +++--- 6 files changed, 64 insertions(+), 57 deletions(-) diff --git a/capture/output/nuxt-dev-plain-restart.svg b/capture/output/nuxt-dev-plain-restart.svg index 42e9f1b2e..194861aee 100644 --- a/capture/output/nuxt-dev-plain-restart.svg +++ b/capture/output/nuxt-dev-plain-restart.svg @@ -16,26 +16,29 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (plain output, restart on config change) - -⠙ Starting Nuxt... 0.0ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose⠸ Setting up modules 0.0ms · total 121ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠴ Preparing app 0.0ms · total 235ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠦ Preparing app 144ms · total 379ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠏ Generating types 38ms · total 554ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠙ Bundling app 2.0ms · total 726ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠼ Building server 40ms · total 900ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠴ Building server 131ms · total 991ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠦ Building server 226ms · total 1.08s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠧ Building server 311ms · total 1.17s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠇ Building server 392ms · total 1.25s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠏ Building server 515ms · total 1.37s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms⠋ Building server 597ms · total 1.45s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcuts -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated -➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms -➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 96ms · total 820ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms✔ Nuxt Nitro server built in 653ms nitro - WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 10ms✔ Nuxt Nitro server built in 881ms nitro│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms✔ Nuxt Nitro server built in 653ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed -│◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms✔ Nuxt Nitro server built in 653ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 15ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 11ms -◆ Ready in 1.82s →http://localhost:3000/│config 121ms · modules 114ms · app 281ms · types 208ms · bundle 136ms · server 967mspressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 21ms✔ Vite server built in 18ms✔ Nuxt Nitro server built in 653ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 15ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 11ms✔ Nuxt Nitro server built in 573ms nitro + +⠙ Starting Nuxt... 0.0ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose⠸ Setting up modules 0.0ms · total 154ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠴ Preparing app 0.0ms · total 299ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠦ Preparing app 180ms · total 479ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠏ Generating types 5.0ms · total 652ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠋ Generating types 95ms · total 742ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 3.0ms · total 915ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠼ Building server 0.0ms · total 1.07s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠴ Building server 52ms · total 1.13s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠧ Building server 212ms · total 1.29s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠇ Building server 297ms · total 1.37s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠋ Building server 466ms · total 1.54s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠙ Building server 546ms · total 1.62s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠹ Building server 627ms · total 1.70s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠸ Building server 708ms · total 1.78s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms⠼ Building server 788ms · total 1.86s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms✔ Nuxt Nitro server built in 1050ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 154ms · modules 145ms · app 348ms · types 265ms · bundle 167ms · server 1.13spressh + enterto see available shortcuts +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms✔ Nuxt Nitro server built in 1050ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 154ms · modules 145ms · app 348ms · types 265ms · bundle 167ms · server 1.13spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated +➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms✔ Nuxt Nitro server built in 1050ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 154ms · modules 145ms · app 348ms · types 265ms · bundle 167ms · server 1.13spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 20ms✔ Vite server built in 24ms +➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms✔ Nuxt Nitro server built in 1050ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 154ms · modules 145ms · app 348ms · types 265ms · bundle 167ms · server 1.13spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 20ms✔ Vite server built in 24ms✔ Nuxt Nitro server built in 771ms nitro +⠸ Bundling app 116ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 12ms✔ Nuxt Nitro server built in 1050ms nitro│◆ Ready in 2.21s →http://localhost:3000/│config 154ms · modules 145ms · app 348ms · types 265ms · bundle 167ms · server 1.13spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 20ms✔ Vite server built in 24ms✔ Nuxt Nitro server built in 771ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) +│◆ Ready in 2.21s →http://localhost:3000/│config 154ms · modules 145ms · app 348ms · types 265ms · bundle 167ms · server 1.13spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 20ms✔ Vite server built in 24ms✔ Nuxt Nitro server built in 771ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 18ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 14ms +◆ Ready in 2.21s →http://localhost:3000/│config 154ms · modules 145ms · app 348ms · types 265ms · bundle 167ms · server 1.13spressh + enterto see available shortcutsℹ nuxt.config.ts changed. Reloading Nuxt...devtools updatedℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 20ms✔ Vite server built in 24ms✔ Nuxt Nitro server built in 771ms nitroℹ nuxt.config.ts changed. Reloading Nuxt...devtools updated ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3) WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 18ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 14ms✔ Nuxt Nitro server built in 681ms nitro diff --git a/capture/output/nuxt-dev-plain-restart.txt b/capture/output/nuxt-dev-plain-restart.txt index 2d2b15f9c..bc491c37b 100644 --- a/capture/output/nuxt-dev-plain-restart.txt +++ b/capture/output/nuxt-dev-plain-restart.txt @@ -1,4 +1,4 @@ -styles: 8420d148a08cc212 +styles: b9481c350ba0bd29 devtools updated press h + enter to see available shortcuts ➜ DevTools: press Shift + Alt + D in the browser (x.y.z) @@ -15,9 +15,9 @@ styles: 8420d148a08cc212 ✔ Nuxt Nitro server built in 42 ms nitro ✔ Vite client built in 42 ms ✔ Vite server built in 42 ms -⠋ Building server 42 ms · total 42 ms -⠋ Bundling app 42 ms · total 42 ms -⠋ Generating types 42 ms · total 42 ms -⠋ Preparing app 42 ms · total 42 ms -⠋ Setting up modules 42 ms · total 42 ms +⠋ Building server 42 ms +⠋ Bundling app 42 ms +⠋ Generating types 42 ms +⠋ Preparing app 42 ms +⠋ Setting up modules 42 ms ⠋ Starting Nuxt... 42 ms diff --git a/capture/output/nuxt-dev-plain-static.svg b/capture/output/nuxt-dev-plain-static.svg index bd8eb6a35..eca73ae41 100644 --- a/capture/output/nuxt-dev-plain-static.svg +++ b/capture/output/nuxt-dev-plain-static.svg @@ -16,6 +16,6 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (plain output, ready) -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 91ms · total 815ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 34ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 11ms✔ Nuxt Nitro server built in 866ms nitro│◆ Ready in 1.79s →http://localhost:3000/│config 122ms · modules 116ms · app 278ms · types 208ms · bundle 133ms · server 942mspressh + enterto see available shortcuts +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 114ms · total 1.02s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite client built in 43ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 13ms✔ Nuxt Nitro server built in 1041ms nitro│◆ Ready in 2.20s →http://localhost:3000/│config 153ms · modules 144ms · app 353ms · types 264ms · bundle 167ms · server 1.12spressh + enterto see available shortcuts diff --git a/capture/output/nuxt-dev-plain-static.txt b/capture/output/nuxt-dev-plain-static.txt index 40b764d8c..604022800 100644 --- a/capture/output/nuxt-dev-plain-static.txt +++ b/capture/output/nuxt-dev-plain-static.txt @@ -1,4 +1,4 @@ -styles: 7e3af84ab72118eb +styles: 0b16b2e9f0d61733 press h + enter to see available shortcuts ➜ DevTools: press Shift + Alt + D in the browser (x.y.z) ➜ Local: http://localhost:3000/ @@ -12,9 +12,9 @@ styles: 7e3af84ab72118eb ✔ Nuxt Nitro server built in 42 ms nitro ✔ Vite client built in 42 ms ✔ Vite server built in 42 ms -⠋ Building server 42 ms · total 42 ms -⠋ Bundling app 42 ms · total 42 ms -⠋ Generating types 42 ms · total 42 ms -⠋ Preparing app 42 ms · total 42 ms -⠋ Setting up modules 42 ms · total 42 ms +⠋ Building server 42 ms +⠋ Bundling app 42 ms +⠋ Generating types 42 ms +⠋ Preparing app 42 ms +⠋ Setting up modules 42 ms ⠋ Starting Nuxt... 42 ms diff --git a/capture/output/nuxt-dev-plain.svg b/capture/output/nuxt-dev-plain.svg index 945417354..b12a45553 100644 --- a/capture/output/nuxt-dev-plain.svg +++ b/capture/output/nuxt-dev-plain.svg @@ -16,22 +16,26 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (plain output) - -⠙ Starting Nuxt... 0.0ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose⠸ Setting up modules 0.0ms · total 122ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠴ Preparing app 0.0ms · total 238ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠦ Preparing app 145ms · total 383ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠇ Generating types 0.0ms · total 516ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠏ Generating types 42ms · total 558ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠙ Bundling app 2.0ms · total 722ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠼ Building server 0.0ms · total 914ms -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠴ Building server 90ms · total 1.00s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠦ Building server 183ms · total 1.09s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠧ Building server 270ms · total 1.18s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠇ Building server 353ms · total 1.26s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠏ Building server 433ms · total 1.34s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms⠙ Building server 618ms · total 1.53s -│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 89ms · total 809ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 42ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 20ms✔ Nuxt Nitro server built in 857ms nitro│◆ Ready in 1.89s →http://localhost:3000/│config 122ms · modules 116ms · app 278ms · types 204ms · bundle 194ms · server 983mspressh + enterto see available shortcuts + +⠙ Starting Nuxt... 1.0ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose⠸ Setting up modules 0.0ms · total 153ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠴ Preparing app 0.0ms · total 297ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠦ Preparing app 180ms · total 477ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠇ Generating types 0.0ms · total 660ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠏ Generating types 4.0ms · total 664ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠋ Generating types 98ms · total 758ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠹ Bundling app 3.0ms · total 924ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠴ Building server 0.0ms · total 1.13s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠦ Building server 72ms · total 1.21s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠧ Building server 151ms · total 1.29s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠇ Building server 232ms · total 1.37s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠏ Building server 342ms · total 1.48s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠋ Building server 422ms · total 1.56s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠙ Building server 519ms · total 1.65s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠹ Building server 615ms · total 1.75s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠼ Building server 800ms · total 1.93s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms⠴ Building server 880ms · total 2.01s +│●Nuxt 4.6.2 (with Nitro 2.13.4, Vite 8.3.4 and Vue 3.5.44)➜Local: http://localhost:3000/➜Network: use --host to expose ➜ DevTools: press Shift + Alt + D in the browser (v3.4.3)⠸ Bundling app 117ms · total 1.03s WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in aℹ Re-optimizing dependencies because vite config has changed✔ Vite client built in 53ms WARN Plugin "nuxt:devtools:config-retriever" defines Vite-specific hooks (configResolved) in a✔ Vite server built in 25ms✔ Nuxt Nitro server built in 1052ms nitro│◆ Ready in 2.37s →http://localhost:3000/│config 153ms · modules 144ms · app 363ms · types 261ms · bundle 218ms · server 1.23spressh + enterto see available shortcuts diff --git a/capture/output/nuxt-dev-plain.txt b/capture/output/nuxt-dev-plain.txt index c3e3e9ef4..406c17709 100644 --- a/capture/output/nuxt-dev-plain.txt +++ b/capture/output/nuxt-dev-plain.txt @@ -1,4 +1,4 @@ -styles: 8fd08b59c97840b9 +styles: d2449122d4dda2b2 press h + enter to see available shortcuts ➜ DevTools: press Shift + Alt + D in the browser (x.y.z) ➜ Local: http://localhost:3000/ @@ -12,9 +12,9 @@ styles: 8fd08b59c97840b9 ✔ Nuxt Nitro server built in 42 ms nitro ✔ Vite client built in 42 ms ✔ Vite server built in 42 ms -⠋ Building server 42 ms · total 42 ms -⠋ Bundling app 42 ms · total 42 ms -⠋ Generating types 42 ms · total 42 ms -⠋ Preparing app 42 ms · total 42 ms -⠋ Setting up modules 42 ms · total 42 ms +⠋ Building server 42 ms +⠋ Bundling app 42 ms +⠋ Generating types 42 ms +⠋ Preparing app 42 ms +⠋ Setting up modules 42 ms ⠋ Starting Nuxt... 42 ms From 90eb4df7c0d6d76dc3e18b1a927fe0a51d03e5aa Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Thu, 12 Nov 2026 10:57:28 +0000 Subject: [PATCH 15/38] [autofix.ci] apply automated fixes (attempt 2/3) --- capture/output/nuxt-dev-install-module.svg | 91 ++++++++++------------ capture/output/nuxt-dev-install-module.txt | 15 +--- 2 files changed, 42 insertions(+), 64 deletions(-) diff --git a/capture/output/nuxt-dev-install-module.svg b/capture/output/nuxt-dev-install-module.svg index 8f0f4bf8f..a423e42fe 100644 --- a/capture/output/nuxt-dev-install-module.svg +++ b/capture/output/nuxt-dev-install-module.svg @@ -16,55 +16,46 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (module auto-install) -⣠⣦⣠⡀Nuxt4.6.1━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING preparing your apprrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/⠋━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING starting Nuxt...oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━17% · 153ms STARTING setting up modulesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 323ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 509ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 685ms STARTING generating typesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 748ms STARTING generating typesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━67% · 972ms STARTING bundling appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.13s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.22s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.34s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.46s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.58s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.71s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.83s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.95s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⚠ 1 warning READY watching for changesrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○No -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }})Learn more: https://vite.dev/guide/dep-pre-bundling.html -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠴ installing with npm · 0.0ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠦ installing with npm · 96ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠧ installing with npm · 217ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠇ installing with npm · 337ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠏ installing with npm · 458ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠋ installing with npm · 578ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠙ installing with npm · 698ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠹ installing with npm · 818ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠸ installing with npm · 938ms READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠼ installing with npm · 1.05s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠴ installing with npm · 1.17s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠦ installing with npm · 1.29s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠧ installing with npm · 1.41s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠇ installing with npm · 1.53s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠏ installing with npm · 1.65s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠋ installing with npm · 1.77s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠙ installing with npm · 1.90s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠹ installing with npm · 2.02s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠸ installing with npm · 2.14s READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/⠼ installing @nuxt/scripts... · 2.30s READY ✔dependencies installed · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━17% · 52ms BUILDING ✔dependencies installed · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 130ms BUILDING ✔dependencies installed · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━67% · 241ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 308ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 422ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 544ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 686ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 809ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 932ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/✔ 1 request 108ms median READY ✔installed @nuxt/scripts · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.1ready in 2.48sLocalhttp://localhost:3000/✔ 1 request 108ms median READY watching for changes · GET /scripts · 200 · 108msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING preparing your appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━17% · 78ms STARTING setting up modulesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 158ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 253ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 373ms STARTING generating typesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━67% · 549ms STARTING bundling appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 581ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 669ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 790ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 909ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.02s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/⚠ 1 warning STARTING preparing your appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⚠ 1 warning READY watching for changesrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○No +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠏ installing with npm · 0.0ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠋ installing with npm · 106ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠙ installing with npm · 227ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠹ installing with npm · 347ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠸ installing with npm · 467ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠼ installing with npm · 588ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠴ installing with npm · 708ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠦ installing with npm · 828ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠧ installing with npm · 949ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠇ installing with npm · 1.06s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠏ installing with npm · 1.18s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠋ installing with npm · 1.30s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠙ installing with npm · 1.43s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠹ installing with npm · 1.55s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠸ installing with npm · 1.67s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠼ installing with npm · 1.79s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠴ installing with npm · 1.91s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠦ installing with npm · 2.03s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠧ installing with npm · 2.15s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━0% · 0.0ms BUILDING ✔dependencies installed · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 58ms BUILDING ✔dependencies installed · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 145ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 224ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 345ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 465ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/✔ 1 request 62ms median READY ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/✔ 1 request 62ms median READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit diff --git a/capture/output/nuxt-dev-install-module.txt b/capture/output/nuxt-dev-install-module.txt index dae5d6b1d..b44662fcb 100644 --- a/capture/output/nuxt-dev-install-module.txt +++ b/capture/output/nuxt-dev-install-module.txt @@ -1,9 +1,4 @@ -styles: a057ea820f39fe11 - '@vue/devtools-core', - ] - include: [ - optimizeDeps: { - } +styles: c631b1f09ab5adaa Local http://localhost:3000/ Local http://localhost:3000/ ⠋ ━━━━━━━━━━━━━━━━━━━━ 0% · 42 ms @@ -18,7 +13,6 @@ styles: a057ea820f39fe11 ✔ 1 request 42 ms median ⚠ 2 warnings ⠋ installing @nuxt/scripts... · 42 ms ⠋ installing with npm · 42 ms - @vue/devtools-core ← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.js BUILDING ✔ dependencies installed · GET /scripts · 200 · 42 ms BUILDING ✔ installed @nuxt/scripts · GET /scripts · 200 · 42 ms READY watching for changes @@ -32,18 +26,11 @@ styles: a057ea820f39fe11 STARTING preparing your app STARTING setting up modules STARTING starting Nuxt... - vite: { - } o open · i info · l logs · n network · p routes · ? help · q quit r restart · o open · i info · l logs · n network · p routes · ? help · q quit ⣠⣦⣠⡀ Nuxt x.y.z ⣠⣦⣠⡀ Nuxt x.y.z ready in 42 ms -Learn more: https://vite.dev/guide/dep-pre-bundling.html -Pre-bundle them in your nuxt.config.ts to avoid page reloads: Yes -export default defineNuxtConfig({ -}) -ℹ Vite discovered new dependencies at runtime: ● Yes / ○ No ✔ Do you want to install @nuxt/scripts package? ❯ Do you want to install @nuxt/scripts package? From b8f957a2ad0cdf788210f78ce8dd561b32a4c705 Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Thu, 12 Nov 2026 10:59:31 +0000 Subject: [PATCH 16/38] [autofix.ci] apply automated fixes (attempt 3/3) --- capture/output/nuxt-dev-install-module.svg | 84 +++++++++++----------- capture/output/nuxt-dev-install-module.txt | 15 +++- 2 files changed, 57 insertions(+), 42 deletions(-) diff --git a/capture/output/nuxt-dev-install-module.svg b/capture/output/nuxt-dev-install-module.svg index a423e42fe..d3accb209 100644 --- a/capture/output/nuxt-dev-install-module.svg +++ b/capture/output/nuxt-dev-install-module.svg @@ -16,46 +16,48 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (module auto-install) -⣠⣦⣠⡀Nuxt4.6.2━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING preparing your appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━17% · 78ms STARTING setting up modulesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 158ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 253ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 373ms STARTING generating typesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━67% · 549ms STARTING bundling appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 581ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 669ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 790ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 909ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.02s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/⚠ 1 warning STARTING preparing your appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⚠ 1 warning READY watching for changesrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○No -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠏ installing with npm · 0.0ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠋ installing with npm · 106ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠙ installing with npm · 227ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠹ installing with npm · 347ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠸ installing with npm · 467ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠼ installing with npm · 588ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠴ installing with npm · 708ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠦ installing with npm · 828ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠧ installing with npm · 949ms READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠇ installing with npm · 1.06s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠏ installing with npm · 1.18s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠋ installing with npm · 1.30s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠙ installing with npm · 1.43s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠹ installing with npm · 1.55s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠸ installing with npm · 1.67s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠼ installing with npm · 1.79s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠴ installing with npm · 1.91s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠦ installing with npm · 2.03s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/⠧ installing with npm · 2.15s READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━0% · 0.0ms BUILDING ✔dependencies installed · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 58ms BUILDING ✔dependencies installed · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 145ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 224ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 345ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 465ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/✔ 1 request 62ms median READY ✔installed @nuxt/scripts · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.30sLocalhttp://localhost:3000/✔ 1 request 62ms median READY watching for changes · GET /scripts · 200 · 62msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING preparing your apprrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/⠋━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING starting Nuxt...oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━17% · 94ms STARTING setting up modulesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 180ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 289ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 415ms STARTING generating typesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━67% · 560ms STARTING bundling appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 680ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 800ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 922ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.04s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.16s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⚠ 1 warning READY watching for changesrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○No +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }})Learn more: https://vite.dev/guide/dep-pre-bundling.html +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠋ installing with npm · 0.0ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠙ installing with npm · 105ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠹ installing with npm · 226ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠸ installing with npm · 347ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠼ installing with npm · 467ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠴ installing with npm · 588ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠦ installing with npm · 709ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠧ installing with npm · 830ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠇ installing with npm · 950ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠏ installing with npm · 1.07s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠋ installing with npm · 1.19s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠙ installing with npm · 1.31s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠹ installing with npm · 1.43s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠸ installing with npm · 1.55s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠼ installing with npm · 1.67s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠴ installing with npm · 1.79s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠦ installing with npm · 1.91s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠧ installing with npm · 2.03s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠇ installing with npm · 2.15s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━0% · 0.0ms BUILDING ✔dependencies installed · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 87ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 156ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 208ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 329ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 449ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 570ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/✔ 1 request 78ms median READY ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/✔ 1 request 78ms median READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit diff --git a/capture/output/nuxt-dev-install-module.txt b/capture/output/nuxt-dev-install-module.txt index b44662fcb..dae5d6b1d 100644 --- a/capture/output/nuxt-dev-install-module.txt +++ b/capture/output/nuxt-dev-install-module.txt @@ -1,4 +1,9 @@ -styles: c631b1f09ab5adaa +styles: a057ea820f39fe11 + '@vue/devtools-core', + ] + include: [ + optimizeDeps: { + } Local http://localhost:3000/ Local http://localhost:3000/ ⠋ ━━━━━━━━━━━━━━━━━━━━ 0% · 42 ms @@ -13,6 +18,7 @@ styles: c631b1f09ab5adaa ✔ 1 request 42 ms median ⚠ 2 warnings ⠋ installing @nuxt/scripts... · 42 ms ⠋ installing with npm · 42 ms + @vue/devtools-core ← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.js BUILDING ✔ dependencies installed · GET /scripts · 200 · 42 ms BUILDING ✔ installed @nuxt/scripts · GET /scripts · 200 · 42 ms READY watching for changes @@ -26,11 +32,18 @@ styles: c631b1f09ab5adaa STARTING preparing your app STARTING setting up modules STARTING starting Nuxt... + vite: { + } o open · i info · l logs · n network · p routes · ? help · q quit r restart · o open · i info · l logs · n network · p routes · ? help · q quit ⣠⣦⣠⡀ Nuxt x.y.z ⣠⣦⣠⡀ Nuxt x.y.z ready in 42 ms +Learn more: https://vite.dev/guide/dep-pre-bundling.html +Pre-bundle them in your nuxt.config.ts to avoid page reloads: Yes +export default defineNuxtConfig({ +}) +ℹ Vite discovered new dependencies at runtime: ● Yes / ○ No ✔ Do you want to install @nuxt/scripts package? ❯ Do you want to install @nuxt/scripts package? From 5f7e5b762f62f7441fa06ed0de32e971408cfdaa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 11:03:00 +0000 Subject: [PATCH 17/38] fix(capture): pre-bundle @vue/devtools-core in the capture fixture Whether Vite discovered @vue/devtools-core while serving the first request depended on timing, so nuxt-dev-install-module printed Vite's optimizeDeps hint in some recordings and not others, and autofix.ci kept re-recording it. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- capture/fixture/nuxt.config.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/capture/fixture/nuxt.config.ts b/capture/fixture/nuxt.config.ts index 282f9de59..4497cacba 100644 --- a/capture/fixture/nuxt.config.ts +++ b/capture/fixture/nuxt.config.ts @@ -5,4 +5,11 @@ export default defineNuxtConfig({ tasks: true, }, }, + vite: { + // Pre-bundled so Vite never discovers it while serving the first request: + // whether it does depends on timing, and its hint would flip the captures. + optimizeDeps: { + include: ['@vue/devtools-core'], + }, + }, }) From e171a8cacfa303c307dd6c53e86665721ed7a185 Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Thu, 12 Nov 2026 11:05:03 +0000 Subject: [PATCH 18/38] [autofix.ci] apply automated fixes --- capture/output/nuxt-dev-install-module.svg | 85 +++++++++++----------- capture/output/nuxt-dev-install-module.txt | 15 +--- 2 files changed, 43 insertions(+), 57 deletions(-) diff --git a/capture/output/nuxt-dev-install-module.svg b/capture/output/nuxt-dev-install-module.svg index d3accb209..f2f6621b6 100644 --- a/capture/output/nuxt-dev-install-module.svg +++ b/capture/output/nuxt-dev-install-module.svg @@ -16,48 +16,47 @@ svg{--bg:#ffffff;--fg:#24292f;--chrome:#f6f8fa;--dot:#d0d7de} nuxt dev (module auto-install) -⣠⣦⣠⡀Nuxt4.6.2━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING preparing your apprrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/⠋━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING starting Nuxt...oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━17% · 94ms STARTING setting up modulesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 180ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 289ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 415ms STARTING generating typesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━67% · 560ms STARTING bundling appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 680ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 800ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 922ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.04s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.16s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⚠ 1 warning READY watching for changesrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○No -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }})Learn more: https://vite.dev/guide/dep-pre-bundling.html -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠋ installing with npm · 0.0ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠙ installing with npm · 105ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠹ installing with npm · 226ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠸ installing with npm · 347ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠼ installing with npm · 467ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠴ installing with npm · 588ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠦ installing with npm · 709ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠧ installing with npm · 830ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠇ installing with npm · 950ms READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠏ installing with npm · 1.07s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠋ installing with npm · 1.19s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠙ installing with npm · 1.31s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠹ installing with npm · 1.43s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠸ installing with npm · 1.55s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠼ installing with npm · 1.67s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠴ installing with npm · 1.79s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠦ installing with npm · 1.91s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠧ installing with npm · 2.03s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/⠇ installing with npm · 2.15s READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━0% · 0.0ms BUILDING ✔dependencies installed · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 87ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 156ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 208ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 329ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 449ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 570ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/✔ 1 request 78ms median READY ✔installed @nuxt/scripts · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit -❯ Do you want to install @nuxt/scripts package?● Yes /○Noℹ Vite discovered new dependencies at runtime:@vue/devtools-core← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.jsPre-bundle them in your nuxt.config.ts to avoid page reloads:export default defineNuxtConfig({ vite: { optimizeDeps: { include: [ '@vue/devtools-core', ] } }✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.55sLocalhttp://localhost:3000/✔ 1 request 78ms median READY watching for changes · GET /scripts · 200 · 78msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING preparing your apprrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/⠋━━━━━━━━━━━━━━━━━━━━0% · 0.0ms STARTING starting Nuxt...oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━17% · 96ms STARTING setting up modulesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 193ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━33% · 304ms STARTING preparing appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 435ms STARTING generating typesoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━67% · 580ms STARTING bundling appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 701ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 821ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 942ms STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.07s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 1.19s STARTING building serveroopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/⚠ 1 warning STARTING preparing your appoopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⚠ 1 warning READY watching for changesrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +❯ Do you want to install @nuxt/scripts package?● Yes /○No +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠋ installing with npm · 0.0ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠙ installing with npm · 104ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠹ installing with npm · 225ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠸ installing with npm · 346ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠼ installing with npm · 466ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠴ installing with npm · 587ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠦ installing with npm · 706ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠧ installing with npm · 827ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠇ installing with npm · 948ms READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠏ installing with npm · 1.06s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠋ installing with npm · 1.19s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠙ installing with npm · 1.31s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠹ installing with npm · 1.43s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠸ installing with npm · 1.55s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠼ installing with npm · 1.67s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠴ installing with npm · 1.79s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠦ installing with npm · 1.91s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠧ installing with npm · 2.03s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/⠇ installing with npm · 2.15s READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━0% · 0.0ms BUILDING ✔dependencies installed · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━50% · 86ms BUILDING ✔dependencies installed · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 156ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 208ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 328ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2Localhttp://localhost:3000/━━━━━━━━━━━━━━━━━━━━83% · 472ms BUILDING ✔installed @nuxt/scripts · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/✔ 1 request 70ms median READY ✔installed @nuxt/scripts · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit +✔ Do you want to install @nuxt/scripts package?Yes⣠⣦⣠⡀Nuxt4.6.2ready in 1.56sLocalhttp://localhost:3000/✔ 1 request 70ms median READY watching for changes · GET /scripts · 200 · 70msrrestart · oopen · iinfo · llogs · nnetwork · proutes · ?help · qquit diff --git a/capture/output/nuxt-dev-install-module.txt b/capture/output/nuxt-dev-install-module.txt index dae5d6b1d..b44662fcb 100644 --- a/capture/output/nuxt-dev-install-module.txt +++ b/capture/output/nuxt-dev-install-module.txt @@ -1,9 +1,4 @@ -styles: a057ea820f39fe11 - '@vue/devtools-core', - ] - include: [ - optimizeDeps: { - } +styles: c631b1f09ab5adaa Local http://localhost:3000/ Local http://localhost:3000/ ⠋ ━━━━━━━━━━━━━━━━━━━━ 0% · 42 ms @@ -18,7 +13,6 @@ styles: a057ea820f39fe11 ✔ 1 request 42 ms median ⚠ 2 warnings ⠋ installing @nuxt/scripts... · 42 ms ⠋ installing with npm · 42 ms - @vue/devtools-core ← ./virtual:nuxt:.nuxt%2Fruntime.vue-devtools-client.CN4wuBpFwm.js BUILDING ✔ dependencies installed · GET /scripts · 200 · 42 ms BUILDING ✔ installed @nuxt/scripts · GET /scripts · 200 · 42 ms READY watching for changes @@ -32,18 +26,11 @@ styles: a057ea820f39fe11 STARTING preparing your app STARTING setting up modules STARTING starting Nuxt... - vite: { - } o open · i info · l logs · n network · p routes · ? help · q quit r restart · o open · i info · l logs · n network · p routes · ? help · q quit ⣠⣦⣠⡀ Nuxt x.y.z ⣠⣦⣠⡀ Nuxt x.y.z ready in 42 ms -Learn more: https://vite.dev/guide/dep-pre-bundling.html -Pre-bundle them in your nuxt.config.ts to avoid page reloads: Yes -export default defineNuxtConfig({ -}) -ℹ Vite discovered new dependencies at runtime: ● Yes / ○ No ✔ Do you want to install @nuxt/scripts package? ❯ Do you want to install @nuxt/scripts package? From 590ee4c8010c132d95b660d7641e7877c784545b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 13:29:37 +0000 Subject: [PATCH 19/38] fix(build): count only written prerenders and list failures only when Nitro was muted Skipped routes fire prerender:route without being written, so they no longer count towards the summary. The CLI lists failed routes only when it lowered Nitro's log level itself, so a project that sets its own level does not see them twice, and it reads Nitro 3's status and statusText as well as Nitro 2's statusCode and statusMessage. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/server-output.ts | 12 ++++++++--- .../test/unit/utils/server-output.spec.ts | 21 +++++++++++++++++-- 2 files changed, 28 insertions(+), 5 deletions(-) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index 2ace1702e..5725d1791 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -76,10 +76,13 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) size = dir ? await directorySize(dir).catch(() => undefined) : undefined } + // Whether the CLI took Nitro's output over, and so owes what it hid. + let nitroQuieted = false if (quiet) { nuxt.hook('nitro:config', (config) => { if (nuxt.options.nitro?.logLevel === undefined && Number(config.logLevel ?? 3) > NITRO_QUIET_LOG_LEVEL) { config.logLevel = NITRO_QUIET_LOG_LEVEL + nitroQuieted = true } }) } @@ -152,13 +155,14 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) nuxt.hook('nitro:init', (nitro) => { usesNitro = true nitro.hooks.hook('prerender:route', (route) => { - if (!route.error) { + // A skipped route fires the hook without being written. + if (!route.error && !route.skip) { prerendered++ } }) nitro.hooks.hook('prerender:done', ({ failedRoutes }) => { // Nitro lists these at its `log` level, which the quiet build drops. - if (failedRoutes.length && quiet) { + if (failedRoutes.length && nitroQuieted) { logger.error(`Failed to prerender ${failedRoutes.length} route${failedRoutes.length === 1 ? '' : 's'}:\n${ failedRoutes.map(formatFailedRoute).join('\n')}`) } @@ -194,7 +198,9 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) } function formatFailedRoute(route: PrerenderRoute): string { - const status = [route.error?.statusCode, route.error?.statusMessage].filter(Boolean).join(' ') + // Nitro 2 sets `statusCode` and `statusMessage`; Nitro 3 `status` and `statusText`. + const error = route.error as (PrerenderRoute['error'] & { status?: number, statusText?: string }) | undefined + const status = [error?.statusCode ?? error?.status, error?.statusMessage ?? error?.statusText].filter(Boolean).join(' ') return ` ${route.route}${status ? styleText('dim', ` (${status})`) : ''}` } diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index 45eeb74f3..37954fe21 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -135,10 +135,16 @@ describe('quietServerOutput', () => { options: { output: { serverDir, dir }, commands: { preview: 'node {{ output.serverDir }}/index.mjs' } }, hooks: nitroHooks, } + await hooks.call('nitro:config', { logLevel: 3 }) await hooks.call('nitro:init', nitro) await nitroHooks.call('prerender:route', { route: '/' }) + await nitroHooks.call('prerender:route', { route: '/feed', skip: true }) await nitroHooks.call('prerender:route', { route: '/gone', error: { statusCode: 404 } }) - await nitroHooks.call('prerender:done', { failedRoutes: [{ route: '/gone', error: { statusCode: 404, statusMessage: 'Not Found' } }] }) + // Nitro 2 and Nitro 3 name the HTTP status differently. + await nitroHooks.call('prerender:done', { failedRoutes: [ + { route: '/gone', error: { statusCode: 404, statusMessage: 'Not Found' } }, + { route: '/broken', error: { status: 500, statusText: 'Server Error' } }, + ] }) await nitroHooks.call('compiled', nitro) const timings = [ @@ -151,7 +157,18 @@ describe('quietServerOutput', () => { // Source maps are left out, as Nitro leaves them out of its own total. expect(lines[1]).toBe('Server (nitro) built in 2.50s · 2.50 kB') expect(lines[2]).toBe('Preview: npx nuxt preview') - expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 1 route:\n /gone (404 Not Found)') + expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 2 routes:\n /gone (404 Not Found)\n /broken (500 Server Error)') + }) + + it('leaves failed prerenders to Nitro when the project sets its log level', async () => { + const { nuxt, hooks } = createNuxt({ nitro: { logLevel: 3 } }) + quietServerOutput(nuxt as any) + const nitroHooks = createHooks() + await hooks.call('nitro:config', { logLevel: 3 }) + await hooks.call('nitro:init', { options: { output: { serverDir: '/missing' } }, hooks: nitroHooks }) + await nitroHooks.call('prerender:done', { failedRoutes: [{ route: '/gone', error: { statusCode: 404 } }] }) + + expect(mocks.error).not.toHaveBeenCalled() }) it('reports a server built by Vite when Nitro is not the server builder', async () => { From fbf57f9c7c1ffedfc67cd4f0177700efebf467eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 13:36:13 +0000 Subject: [PATCH 20/38] fix(build): keep Nitro's 'You can preview this build using' wording Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/server-output.ts | 4 ++-- packages/nuxt-cli/test/unit/utils/server-output.spec.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index 5725d1791..3276668bd 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -187,9 +187,9 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) if (!isStatic && server && size !== undefined) { const builder = usesNitro ? 'nitro' : (nuxt as unknown as MaybeServerBuild).serverBuild?.name || 'server' lines.push(`Server (${builder}) built in ${formatDuration(server.duration)}${styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) - lines.push(styleText('dim', `Preview: ${styleText('cyan', 'npx nuxt preview')}`)) + lines.push(`You can preview this build using ${styleText('cyan', 'npx nuxt preview')}`) if (deploy) { - lines.push(styleText('dim', `Deploy: ${styleText('cyan', deploy)}`)) + lines.push(`You can deploy this build using ${styleText('cyan', deploy)}`) } } return lines.length ? lines.join('\n') : undefined diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index 37954fe21..0ae036f4a 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -156,7 +156,7 @@ describe('quietServerOutput', () => { expect(lines[0]).toBe('Prerendered 1 route in 1.20s') // Source maps are left out, as Nitro leaves them out of its own total. expect(lines[1]).toBe('Server (nitro) built in 2.50s · 2.50 kB') - expect(lines[2]).toBe('Preview: npx nuxt preview') + expect(lines[2]).toBe('You can preview this build using npx nuxt preview') expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 2 routes:\n /gone (404 Not Found)\n /broken (500 Server Error)') }) @@ -188,7 +188,7 @@ describe('quietServerOutput', () => { const timings = [{ phase: 'bundle (client)', message: '', duration: 900 }, { phase: 'bundle (server)', message: '', duration: 400 }] expect(stripAnsi(report.summary(timings)!).split('\n')).toEqual([ 'Server (vite) built in 400ms · 1.20 kB', - 'Preview: npx nuxt preview', + 'You can preview this build using npx nuxt preview', ]) }) From e494686976b7217bae58d3e486c60a2cfb321d09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 14:01:51 +0000 Subject: [PATCH 21/38] fix(logger): keep the blank line after the outro when Nuxt wraps stdout Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/logger.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/nuxt-cli/src/utils/logger.ts b/packages/nuxt-cli/src/utils/logger.ts index c81cb21eb..a205fabaa 100644 --- a/packages/nuxt-cli/src/utils/logger.ts +++ b/packages/nuxt-cli/src/utils/logger.ts @@ -93,7 +93,9 @@ export function outro(message: string): void { writeDirect(`${styleText('green', S_SUCCESS)} ${message}\n`) return } - clackOutro(message) + // Nuxt 4 calls `consola.wrapAll()` while building, which trims each chunk + // written to stdout and would drop the blank line clack ends the outro with. + clackOutro(message, { output: { write: writeDirect } as unknown as NodeJS.WriteStream }) } export const debug = createDebug('nuxi') From d9916f28756f33db0874ec4304f62cd32ab8c1ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 14:14:50 +0000 Subject: [PATCH 22/38] feat(build): end the build on how to preview and deploy it Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 10 +++++++++- packages/nuxt-cli/src/utils/logger.ts | 4 +++- packages/nuxt-cli/src/utils/server-output.ts | 16 ++++++++++++---- .../test/unit/utils/server-output.spec.ts | 6 ++++-- 4 files changed, 28 insertions(+), 8 deletions(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 21b7dc1c7..01cfdcee4 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -166,7 +166,15 @@ export default defineCommand({ outro(`✨ You can now deploy ${styleText('cyan', publicDir)} to any static hosting! ${styleText('gray', `(${formatDuration(Date.now() - start)})`)}`) } else { - outro(`✨ Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}!`) + const complete = `✨ Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}!` + const commands = serverOutput.commands() + if (commands.length) { + logger.success(complete) + outro(commands.join('\n')) + } + else { + outro(complete) + } } } finally { diff --git a/packages/nuxt-cli/src/utils/logger.ts b/packages/nuxt-cli/src/utils/logger.ts index a205fabaa..52f1b8722 100644 --- a/packages/nuxt-cli/src/utils/logger.ts +++ b/packages/nuxt-cli/src/utils/logger.ts @@ -90,9 +90,11 @@ export function intro(message: string): void { /** {@link intro}, for the line a command finishes on. */ export function outro(message: string): void { if (!process.stdout.isTTY || isCI) { - writeDirect(`${styleText('green', S_SUCCESS)} ${message}\n`) + writeDirect(`${styleText('green', S_SUCCESS)} ${message.replace(/\n/g, '\n ')}\n`) return } + // Clack leaves the lines after the first unindented; line them up with it. + message = message.replace(/\n/g, '\n ') // Nuxt 4 calls `consola.wrapAll()` while building, which trims each chunk // written to stdout and would drop the blank line clack ends the outro with. clackOutro(message, { output: { write: writeDirect } as unknown as NodeJS.WriteStream }) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index 3276668bd..aa4b5692e 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -26,6 +26,8 @@ const SOURCE_MAP_RE = /\.map(?:\.json)?$/ export interface ServerOutputReport { /** The summary of the server build, from the build's phase timings, or nothing for a static-only build. */ summary: (timings: PhaseTiming[]) => string | undefined + /** How to preview and deploy what was built, or nothing when no server was written. */ + commands: () => string[] } interface ServerOutputOptions { @@ -187,13 +189,19 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) if (!isStatic && server && size !== undefined) { const builder = usesNitro ? 'nitro' : (nuxt as unknown as MaybeServerBuild).serverBuild?.name || 'server' lines.push(`Server (${builder}) built in ${formatDuration(server.duration)}${styleText('dim', ` \u00B7 ${formatBytes(size)}`)}`) - lines.push(`You can preview this build using ${styleText('cyan', 'npx nuxt preview')}`) - if (deploy) { - lines.push(`You can deploy this build using ${styleText('cyan', deploy)}`) - } } return lines.length ? lines.join('\n') : undefined }, + commands() { + if (isStatic || size === undefined) { + return [] + } + const commands = [`You can preview this build using ${styleText('cyan', 'npx nuxt preview')}`] + if (deploy) { + commands.push(`You can deploy this build using ${styleText('cyan', deploy)}`) + } + return commands + }, } } diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index 0ae036f4a..334037e36 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -156,7 +156,8 @@ describe('quietServerOutput', () => { expect(lines[0]).toBe('Prerendered 1 route in 1.20s') // Source maps are left out, as Nitro leaves them out of its own total. expect(lines[1]).toBe('Server (nitro) built in 2.50s · 2.50 kB') - expect(lines[2]).toBe('You can preview this build using npx nuxt preview') + expect(lines).toHaveLength(2) + expect(report.commands().map(stripAnsi)).toEqual(['You can preview this build using npx nuxt preview']) expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 2 routes:\n /gone (404 Not Found)\n /broken (500 Server Error)') }) @@ -188,8 +189,8 @@ describe('quietServerOutput', () => { const timings = [{ phase: 'bundle (client)', message: '', duration: 900 }, { phase: 'bundle (server)', message: '', duration: 400 }] expect(stripAnsi(report.summary(timings)!).split('\n')).toEqual([ 'Server (vite) built in 400ms · 1.20 kB', - 'You can preview this build using npx nuxt preview', ]) + expect(report.commands().map(stripAnsi)).toEqual(['You can preview this build using npx nuxt preview']) }) it('reports nothing about a server for a static build', async () => { @@ -201,6 +202,7 @@ describe('quietServerOutput', () => { await nitroHooks.call('compiled', nitro) expect(report.summary([{ phase: 'bundle (nitro)', message: '', duration: 100 }])).toBeUndefined() + expect(report.commands()).toEqual([]) }) }) From 59ac473b074929ad1dc81cd8d07302bf73dabaa8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 14:17:50 +0000 Subject: [PATCH 23/38] feat(build): drop the sparkles from the build complete line Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 01cfdcee4..09cca09c4 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -166,7 +166,7 @@ export default defineCommand({ outro(`✨ You can now deploy ${styleText('cyan', publicDir)} to any static hosting! ${styleText('gray', `(${formatDuration(Date.now() - start)})`)}`) } else { - const complete = `✨ Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}!` + const complete = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}!` const commands = serverOutput.commands() if (commands.length) { logger.success(complete) From 24642e52cfb7ff01cb72b6c150d37451b02a9c6f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 14:23:43 +0000 Subject: [PATCH 24/38] feat(build): drop the sparkles and exclamation from the static build outro Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 09cca09c4..1f726d68a 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -163,7 +163,7 @@ export default defineCommand({ } const dir = serverBuild.publicDir const publicDir = dir ? relative(process.cwd(), dir) : '.output/public' - outro(`✨ You can now deploy ${styleText('cyan', publicDir)} to any static hosting! ${styleText('gray', `(${formatDuration(Date.now() - start)})`)}`) + outro(`You can now deploy ${styleText('cyan', publicDir)} to any static hosting ${styleText('gray', `(${formatDuration(Date.now() - start)})`)}`) } else { const complete = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}!` From dff1193ee14d9a852d94d13231187d7db9c73087 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 14:24:44 +0000 Subject: [PATCH 25/38] feat(build): drop the exclamation from the build complete line Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 1f726d68a..a5d00dda2 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -166,7 +166,7 @@ export default defineCommand({ outro(`You can now deploy ${styleText('cyan', publicDir)} to any static hosting ${styleText('gray', `(${formatDuration(Date.now() - start)})`)}`) } else { - const complete = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}!` + const complete = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}` const commands = serverOutput.commands() if (commands.length) { logger.success(complete) From a0910896c5cded3cc771eb23aaa1d0c8b0aa058e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 14:35:24 +0000 Subject: [PATCH 26/38] fix(build): keep the deploy command for static presets Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/server-output.ts | 9 +++++---- packages/nuxt-cli/test/unit/utils/server-output.spec.ts | 6 +++--- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index aa4b5692e..9290ddacb 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -26,7 +26,7 @@ const SOURCE_MAP_RE = /\.map(?:\.json)?$/ export interface ServerOutputReport { /** The summary of the server build, from the build's phase timings, or nothing for a static-only build. */ summary: (timings: PhaseTiming[]) => string | undefined - /** How to preview and deploy what was built, or nothing when no server was written. */ + /** How to preview and deploy what was built: no preview when no server was written. */ commands: () => string[] } @@ -193,10 +193,11 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) return lines.length ? lines.join('\n') : undefined }, commands() { - if (isStatic || size === undefined) { - return [] + const commands: string[] = [] + // A static preset writes no server to preview, but may still name a deploy command. + if (!isStatic && size !== undefined) { + commands.push(`You can preview this build using ${styleText('cyan', 'npx nuxt preview')}`) } - const commands = [`You can preview this build using ${styleText('cyan', 'npx nuxt preview')}`] if (deploy) { commands.push(`You can deploy this build using ${styleText('cyan', deploy)}`) } diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index 334037e36..1934c47b2 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -193,16 +193,16 @@ describe('quietServerOutput', () => { expect(report.commands().map(stripAnsi)).toEqual(['You can preview this build using npx nuxt preview']) }) - it('reports nothing about a server for a static build', async () => { + it('reports nothing about a server for a static build, but keeps its deploy command', async () => { const { nuxt, hooks } = createNuxt() const report = quietServerOutput(nuxt as any) const nitroHooks = createHooks() - const nitro = { options: { static: true, output: { serverDir: '/missing' } }, hooks: nitroHooks } + const nitro = { options: { static: true, output: { serverDir: '/missing' }, commands: { deploy: 'npx wrangler pages deploy' } }, hooks: nitroHooks } await hooks.call('nitro:init', nitro) await nitroHooks.call('compiled', nitro) expect(report.summary([{ phase: 'bundle (nitro)', message: '', duration: 100 }])).toBeUndefined() - expect(report.commands()).toEqual([]) + expect(report.commands().map(stripAnsi)).toEqual(['You can deploy this build using npx wrangler pages deploy']) }) }) From a39f1409d4c809d09be7b479c4540f7f1f3fc0f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 14:35:24 +0000 Subject: [PATCH 27/38] feat(build): show each phase on its own line with a bar for its share of the build Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 6 ++--- packages/nuxt-cli/src/utils/phase-reporter.ts | 23 ++++++++++++++++++- .../nuxt-cli/test/unit/phase-reporter.spec.ts | 21 ++++++++++++++++- 3 files changed, 45 insertions(+), 5 deletions(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index a5d00dda2..abc9d7213 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -16,7 +16,7 @@ import { loadKit } from '../utils/kit' import { acquireLock, acquireOutputLock, formatLockError } from '../utils/lockfile' import { intro, logger, outro } from '../utils/logger' import { resolveRootDir } from '../utils/paths' -import { createPhaseReporter, formatPhaseBreakdown } from '../utils/phase-reporter' +import { createPhaseReporter, formatPhaseTable } from '../utils/phase-reporter' import { startCpuProfile, stopCpuProfile } from '../utils/profile' import { resolveServerBuild } from '../utils/server-build' import { quietServerOutput } from '../utils/server-output' @@ -151,9 +151,9 @@ export default defineCommand({ logger.success(serverSummary) } - const breakdown = formatPhaseBreakdown(progress.timings) + const breakdown = formatPhaseTable(progress.timings) if (breakdown) { - logger.message(styleText('dim', breakdown)) + logger.message(breakdown) } if (ctx.args.prerender) { diff --git a/packages/nuxt-cli/src/utils/phase-reporter.ts b/packages/nuxt-cli/src/utils/phase-reporter.ts index d944119f8..8dfa1726b 100644 --- a/packages/nuxt-cli/src/utils/phase-reporter.ts +++ b/packages/nuxt-cli/src/utils/phase-reporter.ts @@ -65,13 +65,34 @@ export function isAnimationSupported(stream: NodeJS.WriteStream = process.stdout } /** `config 40ms · modules 1.2s · …`, or nothing if every phase was trivial. */ -export function formatPhaseBreakdown(timings: PhaseTiming[]): string { +function formatPhaseBreakdown(timings: PhaseTiming[]): string { return timings .filter(timing => timing.duration >= 10) .map(timing => `${timing.phase} ${formatDuration(timing.duration)}`) .join(' · ') } +const PHASE_BAR_WIDTH = 20 + +/** + * One phase per line with a bar for its share of the time all phases took, so + * the slow step stands out at a glance. Phases are listed in the order they ran. + */ +export function formatPhaseTable(timings: PhaseTiming[]): string { + const shown = timings.filter(timing => timing.duration >= 10) + const total = shown.reduce((sum, timing) => sum + timing.duration, 0) + const nameWidth = Math.max(...shown.map(timing => timing.phase.length)) + const durations = shown.map(timing => formatDuration(timing.duration)) + const durationWidth = Math.max(...durations.map(duration => duration.length)) + return shown.map((timing, index) => { + const share = timing.duration / total + const filled = Math.max(1, Math.round(share * PHASE_BAR_WIDTH)) + const bar = styleText('cyan', '█'.repeat(filled)) + styleText('dim', '░'.repeat(PHASE_BAR_WIDTH - filled)) + const percent = `${Math.round(share * 100)}%`.padStart(4) + return `${timing.phase.padEnd(nameWidth)} ${durations[index]!.padStart(durationWidth)} ${bar} ${styleText('dim', percent)}` + }).join('\n') +} + /** * The URL the summary points at, so the address is on screen at the moment the * user is being told they can click it rather than a screenful further up. diff --git a/packages/nuxt-cli/test/unit/phase-reporter.spec.ts b/packages/nuxt-cli/test/unit/phase-reporter.spec.ts index aa9bb90e2..221e1b229 100644 --- a/packages/nuxt-cli/test/unit/phase-reporter.spec.ts +++ b/packages/nuxt-cli/test/unit/phase-reporter.spec.ts @@ -1,6 +1,8 @@ import type { PhaseReporter } from '../../src/utils/phase-reporter' import type { ProgressSnapshot } from '../../src/utils/progress-snapshot' +import { stripVTControlCharacters } from 'node:util' + import { afterEach, describe, expect, it, vi } from 'vitest' import { blankLineBefore, observeOutput, trackOutputSpacing } from '../../src/utils/stdout' @@ -13,7 +15,7 @@ vi.mock('std-env', async importOriginal => ({ process.env.FORCE_COLOR = '3' -const { createPhaseReporter, formatSummary, isAnimationSupported } = await import('../../src/utils/phase-reporter') +const { createPhaseReporter, formatPhaseTable, formatSummary, isAnimationSupported } = await import('../../src/utils/phase-reporter') function snapshot(overrides: Partial = {}): ProgressSnapshot { return { @@ -381,3 +383,20 @@ describe('phase reporter', () => { delete process.env.NO_COLOR }) }) + +describe('formatPhaseTable', () => { + it('lines phases up with a bar for their share of the phases shown', () => { + const table = formatPhaseTable([ + { phase: 'config', message: '', duration: 1000 }, + { phase: 'types', message: '', duration: 5 }, + { phase: 'bundle (client)', message: '', duration: 2900 }, + { phase: 'prerender', message: '', duration: 100 }, + ]) + // `types` is too quick to list, so it is left out of the total as well. + expect(stripVTControlCharacters(table).split('\n')).toEqual([ + 'config 1.00s █████░░░░░░░░░░░░░░░ 25%', + 'bundle (client) 2.90s ███████████████░░░░░ 73%', + 'prerender 100ms █░░░░░░░░░░░░░░░░░░░ 3%', + ]) + }) +}) From 473a9adb2d9b10230696a4c1d1ed36714c678813 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 14:56:48 +0000 Subject: [PATCH 28/38] feat(build): list prerendered routes, all of them in CI A terminal lists the first 20 written routes and points at --logLevel=verbose for the rest. CI logs list every route, skipped ones too, since they are read later to check what was deployed. Nothing is listed when Nitro prints its own. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 5 ++- packages/nuxt-cli/src/utils/server-output.ts | 43 +++++++++++++++++- .../test/unit/utils/server-output.spec.ts | 44 +++++++++++++++++-- 3 files changed, 86 insertions(+), 6 deletions(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index abc9d7213..d29a319cb 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -107,7 +107,10 @@ export default defineCommand({ }) progress.attachNuxt(nuxt) - const serverOutput = quietServerOutput(nuxt, { onEnvironment: environment => progress.enterEnvironment(environment) }) + const serverOutput = quietServerOutput(nuxt, { + command: ctx.args.prerender ? 'generate' : 'build', + onEnvironment: environment => progress.enterEnvironment(environment), + }) showBanner(nuxt) await nuxt.ready() diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index 9290ddacb..a4b26b14e 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -8,6 +8,7 @@ import process from 'node:process' import { styleText } from 'node:util' import { join, relative } from 'pathe' +import { isCI } from 'std-env' import { formatBytes, formatDuration, stripAnsi } from './formatting' import { logger } from './logger' @@ -15,6 +16,9 @@ import { logger } from './logger' /** Nitro's `warn` level: warnings and errors still print, progress and file trees do not. */ const NITRO_QUIET_LOG_LEVEL = 1 +/** How many prerendered routes a local build lists before pointing at verbose output. */ +const PRERENDER_ROUTE_LIMIT = 20 + const VITE_PLUGIN_NAME = 'nuxi:server-output' /** The line Vite opens each environment's build with, e.g. `vite v8.3.5 building ssr environment for production...`. */ @@ -31,6 +35,8 @@ export interface ServerOutputReport { } interface ServerOutputOptions { + /** The command to suggest for the full route list, such as `build` or `generate`. */ + command?: string /** Called as each Vite environment starts building. */ onEnvironment?: (environment: BuildEnvironment) => void } @@ -63,7 +69,7 @@ interface MaybeServerBuild { * build it as a Vite environment, alongside the app. Either way the CLI keeps * Vite's file lists for the client only. * - * Nothing changes at `--log-level verbose`, or when the project sets a log + * Nothing changes at `--logLevel=verbose`, or when the project sets a log * level for Nitro or Vite itself. */ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}): ServerOutputReport { @@ -71,6 +77,7 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) let usesNitro = false let size: number | undefined let prerendered = 0 + const routes: PrerenderRoute[] = [] let deploy: string | undefined let isStatic = false @@ -161,6 +168,9 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) if (!route.error && !route.skip) { prerendered++ } + if (!route.error) { + routes.push(route) + } }) nitro.hooks.hook('prerender:done', ({ failedRoutes }) => { // Nitro lists these at its `log` level, which the quiet build drops. @@ -182,6 +192,10 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) const prerender = timings.find(timing => timing.phase === 'prerender') if (prerender && prerendered) { lines.push(`Prerendered ${prerendered} route${prerendered === 1 ? '' : 's'} in ${formatDuration(prerender.duration)}`) + // Nitro lists routes itself unless the CLI quieted it. + if (nitroQuieted) { + lines.push(...formatPrerenderedRoutes(routes, options.command ?? 'build')) + } } // Without Nitro, the Vite server bundle is the server output. const server = timings.find(timing => timing.phase === (usesNitro ? 'bundle (nitro)' : 'bundle (server)')) @@ -206,6 +220,33 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) } } +/** + * The routes a build wrote. CI logs are read after the fact to check what was + * deployed, so they list every route, skipped ones too; a terminal lists the + * first few and says how to see the rest. + */ +function formatPrerenderedRoutes(routes: PrerenderRoute[], command: string): string[] { + const listed = isCI ? routes : routes.filter(route => !route.skip) + const shown = isCI ? listed : listed.slice(0, PRERENDER_ROUTE_LIMIT) + const width = Math.min(Math.max(...shown.map(route => route.route.length)), 60) + const times = shown.map(route => route.skip ? 'skipped' : formatRouteTime(route.generateTimeMS)) + const timeWidth = Math.max(...times.map(time => time.length)) + const lines = shown.map((route, index) => ` ${route.route.padEnd(width)} ${styleText('dim', times[index]!.padStart(timeWidth))}`.trimEnd()) + const hidden = listed.length - shown.length + if (hidden) { + lines.push(styleText('dim', ` \u2026 and ${hidden} more. Run ${styleText('cyan', `npx nuxt ${command} --logLevel=verbose`)} to see all prerendered routes.`)) + } + return lines +} + +/** Whole milliseconds, as Nitro prints them, until a route takes seconds. */ +function formatRouteTime(ms: number | undefined): string { + if (ms === undefined) { + return '' + } + return ms < 1000 ? `${Math.round(ms)}ms` : formatDuration(ms) +} + function formatFailedRoute(route: PrerenderRoute): string { // Nitro 2 sets `statusCode` and `statusMessage`; Nitro 3 `status` and `statusText`. const error = route.error as (PrerenderRoute['error'] & { status?: number, statusText?: string }) | undefined diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index 1934c47b2..d841995c7 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -7,8 +7,12 @@ import { afterEach, describe, expect, it, vi } from 'vitest' import { formatBytes, stripAnsi } from '../../../src/utils/formatting' import { quietServerOutput } from '../../../src/utils/server-output' -const mocks = vi.hoisted(() => ({ error: vi.fn() })) +const mocks = vi.hoisted(() => ({ error: vi.fn(), isCI: false })) vi.mock('../../../src/utils/logger', () => ({ logger: { error: mocks.error } })) +vi.mock('std-env', async importOriginal => ({ + ...await importOriginal(), + get isCI() { return mocks.isCI }, +})) type Handler = (...args: any[]) => unknown @@ -33,6 +37,7 @@ function createNuxt(options: Record = {}) { let dir: string | undefined afterEach(async () => { vi.clearAllMocks() + mocks.isCI = false if (dir) { await rm(dir, { recursive: true, force: true }) } @@ -137,7 +142,7 @@ describe('quietServerOutput', () => { } await hooks.call('nitro:config', { logLevel: 3 }) await hooks.call('nitro:init', nitro) - await nitroHooks.call('prerender:route', { route: '/' }) + await nitroHooks.call('prerender:route', { route: '/', generateTimeMS: 42 }) await nitroHooks.call('prerender:route', { route: '/feed', skip: true }) await nitroHooks.call('prerender:route', { route: '/gone', error: { statusCode: 404 } }) // Nitro 2 and Nitro 3 name the HTTP status differently. @@ -154,13 +159,44 @@ describe('quietServerOutput', () => { ] const lines = stripAnsi(report.summary(timings)!).split('\n') expect(lines[0]).toBe('Prerendered 1 route in 1.20s') + // Skipped and failed routes stay out of the list. + expect(lines[1]).toBe(' / 42ms') // Source maps are left out, as Nitro leaves them out of its own total. - expect(lines[1]).toBe('Server (nitro) built in 2.50s · 2.50 kB') - expect(lines).toHaveLength(2) + expect(lines[2]).toBe('Server (nitro) built in 2.50s · 2.50 kB') + expect(lines).toHaveLength(3) expect(report.commands().map(stripAnsi)).toEqual(['You can preview this build using npx nuxt preview']) expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 2 routes:\n /gone (404 Not Found)\n /broken (500 Server Error)') }) + async function prerender(count: number, options: { command?: string } = {}) { + const { nuxt, hooks } = createNuxt() + const report = quietServerOutput(nuxt as any, options) + const nitroHooks = createHooks() + await hooks.call('nitro:config', { logLevel: 3 }) + await hooks.call('nitro:init', { options: { output: { serverDir: '/missing' } }, hooks: nitroHooks }) + for (let index = 0; index < count; index++) { + await nitroHooks.call('prerender:route', { route: `/post-${index}`, generateTimeMS: 5 }) + } + await nitroHooks.call('prerender:route', { route: '/feed', skip: true }) + return stripAnsi(report.summary([{ phase: 'prerender', message: '', duration: 900 }])!).split('\n') + } + + it('lists the first 20 written routes in a terminal and says how to see the rest', async () => { + const lines = await prerender(23, { command: 'generate' }) + expect(lines[0]).toBe('Prerendered 23 routes in 900ms') + expect(lines.slice(1, 3)).toEqual([' /post-0 5ms', ' /post-1 5ms']) + expect(lines[20]).toBe(' /post-19 5ms') + expect(lines.slice(21)).toEqual([' … and 3 more. Run npx nuxt generate --logLevel=verbose to see all prerendered routes.']) + }) + + it('lists every route in CI, skipped ones too', async () => { + mocks.isCI = true + const lines = await prerender(23) + expect(lines).toHaveLength(25) + expect(lines.at(-2)).toBe(' /post-22 5ms') + expect(lines.at(-1)).toBe(' /feed skipped') + }) + it('leaves failed prerenders to Nitro when the project sets its log level', async () => { const { nuxt, hooks } = createNuxt({ nitro: { logLevel: 3 } }) quietServerOutput(nuxt as any) From 9319ceb1173bd61c61a6e16325af010ad4266554 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 15:23:11 +0000 Subject: [PATCH 29/38] feat(build): always end on Build complete with the phase table under it Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 34 ++++++++----------- .../nuxt-cli/test/unit/commands/build.spec.ts | 2 +- 2 files changed, 15 insertions(+), 21 deletions(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index d29a319cb..29cd3fb15 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -154,30 +154,24 @@ export default defineCommand({ logger.success(serverSummary) } - const breakdown = formatPhaseTable(progress.timings) - if (breakdown) { - logger.message(breakdown) + if (ctx.args.prerender && !nuxt.options.ssr) { + logger.warn(`HTML content not prerendered because ${styleText('cyan', 'ssr: false')} was set.`) + logger.info(`You can read more in ${styleText('cyan', 'https://nuxt.com/docs/getting-started/deployment#static-hosting')}.`) } - if (ctx.args.prerender) { - if (!nuxt.options.ssr) { - logger.warn(`HTML content not prerendered because ${styleText('cyan', 'ssr: false')} was set.`) - logger.info(`You can read more in ${styleText('cyan', 'https://nuxt.com/docs/getting-started/deployment#static-hosting')}.`) - } - const dir = serverBuild.publicDir - const publicDir = dir ? relative(process.cwd(), dir) : '.output/public' - outro(`You can now deploy ${styleText('cyan', publicDir)} to any static hosting ${styleText('gray', `(${formatDuration(Date.now() - start)})`)}`) + // Where the time went sits right under the total it adds up to. + const breakdown = formatPhaseTable(progress.timings) + const total = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}` + const complete = breakdown ? `${total}\n${breakdown}` : total + const next = ctx.args.prerender + ? [`You can now deploy ${styleText('cyan', serverBuild.publicDir ? relative(process.cwd(), serverBuild.publicDir) : '.output/public')} to any static hosting`] + : serverOutput.commands() + if (next.length) { + logger.success(complete) + outro(next.join('\n')) } else { - const complete = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}` - const commands = serverOutput.commands() - if (commands.length) { - logger.success(complete) - outro(commands.join('\n')) - } - else { - outro(complete) - } + outro(complete) } } finally { diff --git a/packages/nuxt-cli/test/unit/commands/build.spec.ts b/packages/nuxt-cli/test/unit/commands/build.spec.ts index 0b5bf8ef0..140f1fdc2 100644 --- a/packages/nuxt-cli/test/unit/commands/build.spec.ts +++ b/packages/nuxt-cli/test/unit/commands/build.spec.ts @@ -37,7 +37,7 @@ vi.mock('../../../src/utils/lockfile', () => ({ formatLockError: mocks.formatLockError, })) vi.mock('../../../src/utils/logger', () => ({ - logger: { error: vi.fn(), info: vi.fn(), warn: vi.fn(), message: vi.fn() }, + logger: { error: vi.fn(), info: vi.fn(), warn: vi.fn(), message: vi.fn(), success: vi.fn() }, intro: vi.fn(), outro: vi.fn(), })) From 31b59f04cfb577a2fb8c205c3efcbdeba6990b57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 15:34:03 +0000 Subject: [PATCH 30/38] fix(build): align prerendered routes with the rest of the summary Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/server-output.ts | 4 ++-- .../nuxt-cli/test/unit/utils/server-output.spec.ts | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index a4b26b14e..2b897b72f 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -231,10 +231,10 @@ function formatPrerenderedRoutes(routes: PrerenderRoute[], command: string): str const width = Math.min(Math.max(...shown.map(route => route.route.length)), 60) const times = shown.map(route => route.skip ? 'skipped' : formatRouteTime(route.generateTimeMS)) const timeWidth = Math.max(...times.map(time => time.length)) - const lines = shown.map((route, index) => ` ${route.route.padEnd(width)} ${styleText('dim', times[index]!.padStart(timeWidth))}`.trimEnd()) + const lines = shown.map((route, index) => `${route.route.padEnd(width)} ${styleText('dim', times[index]!.padStart(timeWidth))}`.trimEnd()) const hidden = listed.length - shown.length if (hidden) { - lines.push(styleText('dim', ` \u2026 and ${hidden} more. Run ${styleText('cyan', `npx nuxt ${command} --logLevel=verbose`)} to see all prerendered routes.`)) + lines.push(styleText('dim', `\u2026 and ${hidden} more. Run ${styleText('cyan', `npx nuxt ${command} --logLevel=verbose`)} to see all prerendered routes.`)) } return lines } diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index d841995c7..e669a5bd0 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -160,7 +160,7 @@ describe('quietServerOutput', () => { const lines = stripAnsi(report.summary(timings)!).split('\n') expect(lines[0]).toBe('Prerendered 1 route in 1.20s') // Skipped and failed routes stay out of the list. - expect(lines[1]).toBe(' / 42ms') + expect(lines[1]).toBe('/ 42ms') // Source maps are left out, as Nitro leaves them out of its own total. expect(lines[2]).toBe('Server (nitro) built in 2.50s · 2.50 kB') expect(lines).toHaveLength(3) @@ -184,17 +184,17 @@ describe('quietServerOutput', () => { it('lists the first 20 written routes in a terminal and says how to see the rest', async () => { const lines = await prerender(23, { command: 'generate' }) expect(lines[0]).toBe('Prerendered 23 routes in 900ms') - expect(lines.slice(1, 3)).toEqual([' /post-0 5ms', ' /post-1 5ms']) - expect(lines[20]).toBe(' /post-19 5ms') - expect(lines.slice(21)).toEqual([' … and 3 more. Run npx nuxt generate --logLevel=verbose to see all prerendered routes.']) + expect(lines.slice(1, 3)).toEqual(['/post-0 5ms', '/post-1 5ms']) + expect(lines[20]).toBe('/post-19 5ms') + expect(lines.slice(21)).toEqual(['… and 3 more. Run npx nuxt generate --logLevel=verbose to see all prerendered routes.']) }) it('lists every route in CI, skipped ones too', async () => { mocks.isCI = true const lines = await prerender(23) expect(lines).toHaveLength(25) - expect(lines.at(-2)).toBe(' /post-22 5ms') - expect(lines.at(-1)).toBe(' /feed skipped') + expect(lines.at(-2)).toBe('/post-22 5ms') + expect(lines.at(-1)).toBe('/feed skipped') }) it('leaves failed prerenders to Nitro when the project sets its log level', async () => { From 2921ecec83b79952d63de85087cf095ae05c2d45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 15:36:38 +0000 Subject: [PATCH 31/38] fix(build): align failed prerender routes with their header Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/server-output.ts | 2 +- packages/nuxt-cli/test/unit/utils/server-output.spec.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index 2b897b72f..7328295b6 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -251,7 +251,7 @@ function formatFailedRoute(route: PrerenderRoute): string { // Nitro 2 sets `statusCode` and `statusMessage`; Nitro 3 `status` and `statusText`. const error = route.error as (PrerenderRoute['error'] & { status?: number, statusText?: string }) | undefined const status = [error?.statusCode ?? error?.status, error?.statusMessage ?? error?.statusText].filter(Boolean).join(' ') - return ` ${route.route}${status ? styleText('dim', ` (${status})`) : ''}` + return `${route.route}${status ? styleText('dim', ` (${status})`) : ''}` } /** diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index e669a5bd0..b841c138c 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -165,7 +165,7 @@ describe('quietServerOutput', () => { expect(lines[2]).toBe('Server (nitro) built in 2.50s · 2.50 kB') expect(lines).toHaveLength(3) expect(report.commands().map(stripAnsi)).toEqual(['You can preview this build using npx nuxt preview']) - expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 2 routes:\n /gone (404 Not Found)\n /broken (500 Server Error)') + expect(stripAnsi(mocks.error.mock.calls[0]![0])).toBe('Failed to prerender 2 routes:\n/gone (404 Not Found)\n/broken (500 Server Error)') }) async function prerender(count: number, options: { command?: string } = {}) { From 5d48a21a3cf8aaf4292288bf97d850a0a46e43e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 15:41:00 +0000 Subject: [PATCH 32/38] fix(build): list any number of prerendered routes without spreading them Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/server-output.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index 7328295b6..1733ac1f7 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -194,7 +194,8 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) lines.push(`Prerendered ${prerendered} route${prerendered === 1 ? '' : 's'} in ${formatDuration(prerender.duration)}`) // Nitro lists routes itself unless the CLI quieted it. if (nitroQuieted) { - lines.push(...formatPrerenderedRoutes(routes, options.command ?? 'build')) + // Joined rather than spread: a CI build can list more routes than a call takes arguments. + lines.push(formatPrerenderedRoutes(routes, options.command ?? 'build').join('\n')) } } // Without Nitro, the Vite server bundle is the server output. @@ -228,9 +229,9 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) function formatPrerenderedRoutes(routes: PrerenderRoute[], command: string): string[] { const listed = isCI ? routes : routes.filter(route => !route.skip) const shown = isCI ? listed : listed.slice(0, PRERENDER_ROUTE_LIMIT) - const width = Math.min(Math.max(...shown.map(route => route.route.length)), 60) + const width = Math.min(shown.reduce((max, route) => Math.max(max, route.route.length), 0), 60) const times = shown.map(route => route.skip ? 'skipped' : formatRouteTime(route.generateTimeMS)) - const timeWidth = Math.max(...times.map(time => time.length)) + const timeWidth = times.reduce((max, time) => Math.max(max, time.length), 0) const lines = shown.map((route, index) => `${route.route.padEnd(width)} ${styleText('dim', times[index]!.padStart(timeWidth))}`.trimEnd()) const hidden = listed.length - shown.length if (hidden) { From 38a26b19b4859bcba5a8a9f364c492b71bdf3d60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 15:45:59 +0000 Subject: [PATCH 33/38] fix(build): restore the server builder banner from #1671 A commit that moved the banner change out of this branch replayed on top of #1671 after the rebase and reverted it, so a Vite-built server showed Nitro in the banner again. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/banner.ts | 13 ++++++++++--- packages/nuxt-cli/test/unit/utils/banner.spec.ts | 10 ++++++++++ 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/packages/nuxt-cli/src/utils/banner.ts b/packages/nuxt-cli/src/utils/banner.ts index 59d17c21e..8613dfc40 100644 --- a/packages/nuxt-cli/src/utils/banner.ts +++ b/packages/nuxt-cli/src/utils/banner.ts @@ -5,6 +5,7 @@ import { styleText } from 'node:util' import { logger } from './logger' import { getNitroVersion } from './nitro' import { getNuxtPkgVersion, getPkgJSON, getPkgVersion } from './pkg' +import { getServerBuilderName } from './server-build' export function getBuilder(cwd: string, builder: Exclude): { name: string, version: string, provider?: { name: string, version: string } } { switch (builder) { @@ -30,7 +31,12 @@ export function getBuilder(cwd: string, builder: Exclude { `) }) + it('should omit nitro when another server builder is configured', async () => { + const renderer = await render(() => + showBanner({ _version: '4.4.6', options: { rootDir: '/any', builder: 'vite', server: { builder: '@nuxt/vite-server' } } } as unknown as Nuxt)) + + expect(screen(renderer)).toMatchInlineSnapshot(` + "│ + ● Nuxt 4.4.6 (with Vite 7.3.1 and Vue 3.5.39)" + `) + }) + it('should identify Vite+ as the Vite provider', async () => { const renderer = await render(() => showBanner({ _version: '4.4.6', options: { rootDir: '/vite-plus', builder: 'vite' } } as unknown as Nuxt)) From 598864a8f36be70e1eaa2ad1a9165f198b09a400 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 15:50:58 +0000 Subject: [PATCH 34/38] fix(build): name the project directory in suggested commands Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/utils/server-output.ts | 12 +++++++++--- .../nuxt-cli/test/unit/utils/server-output.spec.ts | 5 +++-- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index 1733ac1f7..e593ff015 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -195,7 +195,7 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) // Nitro lists routes itself unless the CLI quieted it. if (nitroQuieted) { // Joined rather than spread: a CI build can list more routes than a call takes arguments. - lines.push(formatPrerenderedRoutes(routes, options.command ?? 'build').join('\n')) + lines.push(formatPrerenderedRoutes(routes, nuxtCommand(nuxt, options.command ?? 'build')).join('\n')) } } // Without Nitro, the Vite server bundle is the server output. @@ -211,7 +211,7 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) const commands: string[] = [] // A static preset writes no server to preview, but may still name a deploy command. if (!isStatic && size !== undefined) { - commands.push(`You can preview this build using ${styleText('cyan', 'npx nuxt preview')}`) + commands.push(`You can preview this build using ${styleText('cyan', nuxtCommand(nuxt, 'preview'))}`) } if (deploy) { commands.push(`You can deploy this build using ${styleText('cyan', deploy)}`) @@ -226,6 +226,12 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) * deployed, so they list every route, skipped ones too; a terminal lists the * first few and says how to see the rest. */ +/** `npx nuxt `, naming the project when it is not the current directory. */ +function nuxtCommand(nuxt: Nuxt, command: string): string { + const dir = relative(process.cwd(), nuxt.options.rootDir || process.cwd()) + return `npx nuxt ${command}${dir ? ` ${/\s/.test(dir) ? JSON.stringify(dir) : dir}` : ''}` +} + function formatPrerenderedRoutes(routes: PrerenderRoute[], command: string): string[] { const listed = isCI ? routes : routes.filter(route => !route.skip) const shown = isCI ? listed : listed.slice(0, PRERENDER_ROUTE_LIMIT) @@ -235,7 +241,7 @@ function formatPrerenderedRoutes(routes: PrerenderRoute[], command: string): str const lines = shown.map((route, index) => `${route.route.padEnd(width)} ${styleText('dim', times[index]!.padStart(timeWidth))}`.trimEnd()) const hidden = listed.length - shown.length if (hidden) { - lines.push(styleText('dim', `\u2026 and ${hidden} more. Run ${styleText('cyan', `npx nuxt ${command} --logLevel=verbose`)} to see all prerendered routes.`)) + lines.push(styleText('dim', `\u2026 and ${hidden} more. Run ${styleText('cyan', `${command} --logLevel=verbose`)} to see all prerendered routes.`)) } return lines } diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index b841c138c..a8177bd48 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -214,7 +214,8 @@ describe('quietServerOutput', () => { await writeFile(join(dir, 'server/index.mjs'), 'x'.repeat(1200)) await writeFile(join(dir, 'server/index.mjs.map.json'), 'x'.repeat(40_000)) - const { nuxt, hooks } = createNuxt() + // Built from the parent directory, as `nuxt build playground` does. + const { nuxt, hooks } = createNuxt({ rootDir: join(process.cwd(), 'playground') }) Object.assign(nuxt, { serverBuild: { name: 'vite', output: { dir: () => dir } } }) const report = quietServerOutput(nuxt as any) const { plugin } = await resolveVitePlugin(hooks) @@ -226,7 +227,7 @@ describe('quietServerOutput', () => { expect(stripAnsi(report.summary(timings)!).split('\n')).toEqual([ 'Server (vite) built in 400ms · 1.20 kB', ]) - expect(report.commands().map(stripAnsi)).toEqual(['You can preview this build using npx nuxt preview']) + expect(report.commands().map(stripAnsi)).toEqual(['You can preview this build using npx nuxt preview playground']) }) it('reports nothing about a server for a static build, but keeps its deploy command', async () => { From 3e2ae024010b56e960df444c2551780dfd71901f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 15:58:25 +0000 Subject: [PATCH 35/38] feat(build): show the phase timings as one stacked bar with a legend Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 4 +- packages/nuxt-cli/src/utils/phase-reporter.ts | 60 ++++++++++++++----- .../nuxt-cli/test/unit/phase-reporter.spec.ts | 48 ++++++++++----- 3 files changed, 82 insertions(+), 30 deletions(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 29cd3fb15..9be6e3f93 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -16,7 +16,7 @@ import { loadKit } from '../utils/kit' import { acquireLock, acquireOutputLock, formatLockError } from '../utils/lockfile' import { intro, logger, outro } from '../utils/logger' import { resolveRootDir } from '../utils/paths' -import { createPhaseReporter, formatPhaseTable } from '../utils/phase-reporter' +import { createPhaseReporter, formatPhaseBar } from '../utils/phase-reporter' import { startCpuProfile, stopCpuProfile } from '../utils/profile' import { resolveServerBuild } from '../utils/server-build' import { quietServerOutput } from '../utils/server-output' @@ -160,7 +160,7 @@ export default defineCommand({ } // Where the time went sits right under the total it adds up to. - const breakdown = formatPhaseTable(progress.timings) + const breakdown = formatPhaseBar(progress.timings) const total = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}` const complete = breakdown ? `${total}\n${breakdown}` : total const next = ctx.args.prerender diff --git a/packages/nuxt-cli/src/utils/phase-reporter.ts b/packages/nuxt-cli/src/utils/phase-reporter.ts index 8dfa1726b..2f6f9c05e 100644 --- a/packages/nuxt-cli/src/utils/phase-reporter.ts +++ b/packages/nuxt-cli/src/utils/phase-reporter.ts @@ -72,25 +72,57 @@ function formatPhaseBreakdown(timings: PhaseTiming[]): string { .join(' · ') } -const PHASE_BAR_WIDTH = 20 +const PHASE_BAR_WIDTH = 40 + +/** One colour per phase, in the order phases run; a build has at most eight. */ +const PHASE_COLORS = ['blue', 'cyan', 'green', 'yellow', 'magenta', 'red', 'gray', 'blueBright'] as const + +/** Room the clack gutter (`│ `) takes in front of each line. */ +const GUTTER_WIDTH = 3 /** - * One phase per line with a bar for its share of the time all phases took, so - * the slow step stands out at a glance. Phases are listed in the order they ran. + * Where the build's time went in two lines: a bar split into one coloured + * segment per phase, sized by its share of the time all phases took, and a + * legend naming each colour. Without colours the segments cannot be told + * apart, so it falls back to the one-line breakdown. */ -export function formatPhaseTable(timings: PhaseTiming[]): string { +export function formatPhaseBar(timings: PhaseTiming[], columns = process.stdout.columns || 80): string { const shown = timings.filter(timing => timing.duration >= 10) + if (!shown.length) { + return '' + } + if (styleText('red', ' ') === ' ') { + return formatPhaseBreakdown(shown) + } const total = shown.reduce((sum, timing) => sum + timing.duration, 0) - const nameWidth = Math.max(...shown.map(timing => timing.phase.length)) - const durations = shown.map(timing => formatDuration(timing.duration)) - const durationWidth = Math.max(...durations.map(duration => duration.length)) - return shown.map((timing, index) => { - const share = timing.duration / total - const filled = Math.max(1, Math.round(share * PHASE_BAR_WIDTH)) - const bar = styleText('cyan', '█'.repeat(filled)) + styleText('dim', '░'.repeat(PHASE_BAR_WIDTH - filled)) - const percent = `${Math.round(share * 100)}%`.padStart(4) - return `${timing.phase.padEnd(nameWidth)} ${durations[index]!.padStart(durationWidth)} ${bar} ${styleText('dim', percent)}` - }).join('\n') + // Every phase keeps at least one cell so its colour is on the bar; the + // rounding is settled on the largest segment. + const cells = shown.map(timing => Math.max(1, Math.round(timing.duration / total * PHASE_BAR_WIDTH))) + const largest = cells.indexOf(Math.max(...cells)) + cells[largest]! += PHASE_BAR_WIDTH - cells.reduce((sum, count) => sum + count, 0) + + const bar = shown.map((_, index) => styleText(PHASE_COLORS[index % PHASE_COLORS.length]!, '\u2588'.repeat(cells[index]!))).join('') + const entries = shown.map((timing, index) => ({ + text: `\u25A0 ${timing.phase} ${formatDuration(timing.duration)}`, + styled: `${styleText(PHASE_COLORS[index % PHASE_COLORS.length]!, '\u25A0')} ${timing.phase} ${styleText('dim', formatDuration(timing.duration))}`, + })) + + // Wrap the legend between entries rather than letting the terminal split one. + const width = Math.max(columns - GUTTER_WIDTH, 20) + const legend: string[] = [] + let line = '' + let length = 0 + for (const entry of entries) { + if (length && length + 2 + entry.text.length > width) { + legend.push(line) + line = '' + length = 0 + } + line += length ? ` ${entry.styled}` : entry.styled + length += (length ? 2 : 0) + entry.text.length + } + legend.push(line) + return [bar, ...legend].join('\n') } /** diff --git a/packages/nuxt-cli/test/unit/phase-reporter.spec.ts b/packages/nuxt-cli/test/unit/phase-reporter.spec.ts index 221e1b229..edbfb69fa 100644 --- a/packages/nuxt-cli/test/unit/phase-reporter.spec.ts +++ b/packages/nuxt-cli/test/unit/phase-reporter.spec.ts @@ -15,7 +15,7 @@ vi.mock('std-env', async importOriginal => ({ process.env.FORCE_COLOR = '3' -const { createPhaseReporter, formatPhaseTable, formatSummary, isAnimationSupported } = await import('../../src/utils/phase-reporter') +const { createPhaseReporter, formatPhaseBar, formatSummary, isAnimationSupported } = await import('../../src/utils/phase-reporter') function snapshot(overrides: Partial = {}): ProgressSnapshot { return { @@ -384,19 +384,39 @@ describe('phase reporter', () => { }) }) -describe('formatPhaseTable', () => { - it('lines phases up with a bar for their share of the phases shown', () => { - const table = formatPhaseTable([ - { phase: 'config', message: '', duration: 1000 }, - { phase: 'types', message: '', duration: 5 }, - { phase: 'bundle (client)', message: '', duration: 2900 }, - { phase: 'prerender', message: '', duration: 100 }, - ]) +describe('formatPhaseBar', () => { + const timings = [ + { phase: 'config', message: '', duration: 1000 }, + { phase: 'types', message: '', duration: 5 }, + { phase: 'bundle (client)', message: '', duration: 2900 }, + { phase: 'prerender', message: '', duration: 20 }, + ] + + it('splits a 40-cell bar into one segment per phase, sized by its share', () => { + const [bar, ...legend] = formatPhaseBar(timings, 120).split('\n') // `types` is too quick to list, so it is left out of the total as well. - expect(stripVTControlCharacters(table).split('\n')).toEqual([ - 'config 1.00s █████░░░░░░░░░░░░░░░ 25%', - 'bundle (client) 2.90s ███████████████░░░░░ 73%', - 'prerender 100ms █░░░░░░░░░░░░░░░░░░░ 3%', - ]) + // Of 3.92s: config rounds to 10 cells and bundle (client) to 30; prerender + // rounds to none but keeps one, which the largest segment gives back. + const segments = bar!.split('\u001B[').filter(part => part.includes('█')).map(part => [part.slice(0, part.indexOf('m')), part.split('█').length - 1]) + expect(segments).toEqual([['34', 10], ['36', 29], ['32', 1]]) + expect(legend.map(line => stripVTControlCharacters(line))).toEqual(['■ config 1.00s ■ bundle (client) 2.90s ■ prerender 20ms']) + }) + + it('wraps the legend between entries', () => { + const legend = formatPhaseBar(timings, 40).split('\n').slice(1).map(line => stripVTControlCharacters(line)) + expect(legend).toEqual(['■ config 1.00s', '■ bundle (client) 2.90s', '■ prerender 20ms']) + }) + + it('falls back to one line without colours', () => { + process.env.NO_COLOR = '1' + const previous = process.env.FORCE_COLOR + delete process.env.FORCE_COLOR + try { + expect(formatPhaseBar(timings, 120)).toBe('config 1.00s · bundle (client) 2.90s · prerender 20ms') + } + finally { + delete process.env.NO_COLOR + process.env.FORCE_COLOR = previous + } }) }) From f837b1a936a8a4aa268960549cb63ad37bbfd642 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 16:11:25 +0000 Subject: [PATCH 36/38] feat(build): keep the one-line timing breakdown, with the per-phase table at verbose Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 10 +-- packages/nuxt-cli/src/utils/phase-reporter.ts | 62 +++++-------------- .../nuxt-cli/test/unit/phase-reporter.spec.ts | 48 +++++--------- 3 files changed, 35 insertions(+), 85 deletions(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 9be6e3f93..3532b788b 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -16,7 +16,7 @@ import { loadKit } from '../utils/kit' import { acquireLock, acquireOutputLock, formatLockError } from '../utils/lockfile' import { intro, logger, outro } from '../utils/logger' import { resolveRootDir } from '../utils/paths' -import { createPhaseReporter, formatPhaseBar } from '../utils/phase-reporter' +import { createPhaseReporter, formatPhaseBreakdown, formatPhaseTable } from '../utils/phase-reporter' import { startCpuProfile, stopCpuProfile } from '../utils/profile' import { resolveServerBuild } from '../utils/server-build' import { quietServerOutput } from '../utils/server-output' @@ -159,10 +159,12 @@ export default defineCommand({ logger.info(`You can read more in ${styleText('cyan', 'https://nuxt.com/docs/getting-started/deployment#static-hosting')}.`) } - // Where the time went sits right under the total it adds up to. - const breakdown = formatPhaseBar(progress.timings) + // Where the time went sits right under the total it adds up to: one line + // by default, a row per phase with a bar for its share when verbose. + const verbose = nuxt.options.logLevel === 'verbose' + const breakdown = verbose ? formatPhaseTable(progress.timings) : formatPhaseBreakdown(progress.timings) const total = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}` - const complete = breakdown ? `${total}\n${breakdown}` : total + const complete = breakdown ? `${total}\n${verbose ? breakdown : styleText('dim', breakdown)}` : total const next = ctx.args.prerender ? [`You can now deploy ${styleText('cyan', serverBuild.publicDir ? relative(process.cwd(), serverBuild.publicDir) : '.output/public')} to any static hosting`] : serverOutput.commands() diff --git a/packages/nuxt-cli/src/utils/phase-reporter.ts b/packages/nuxt-cli/src/utils/phase-reporter.ts index 2f6f9c05e..2099c9274 100644 --- a/packages/nuxt-cli/src/utils/phase-reporter.ts +++ b/packages/nuxt-cli/src/utils/phase-reporter.ts @@ -65,64 +65,32 @@ export function isAnimationSupported(stream: NodeJS.WriteStream = process.stdout } /** `config 40ms · modules 1.2s · …`, or nothing if every phase was trivial. */ -function formatPhaseBreakdown(timings: PhaseTiming[]): string { +export function formatPhaseBreakdown(timings: PhaseTiming[]): string { return timings .filter(timing => timing.duration >= 10) .map(timing => `${timing.phase} ${formatDuration(timing.duration)}`) .join(' · ') } -const PHASE_BAR_WIDTH = 40 - -/** One colour per phase, in the order phases run; a build has at most eight. */ -const PHASE_COLORS = ['blue', 'cyan', 'green', 'yellow', 'magenta', 'red', 'gray', 'blueBright'] as const - -/** Room the clack gutter (`│ `) takes in front of each line. */ -const GUTTER_WIDTH = 3 +const PHASE_BAR_WIDTH = 20 /** - * Where the build's time went in two lines: a bar split into one coloured - * segment per phase, sized by its share of the time all phases took, and a - * legend naming each colour. Without colours the segments cannot be told - * apart, so it falls back to the one-line breakdown. + * One phase per line with a bar for its share of the time all phases took, so + * the slow step stands out at a glance. Phases are listed in the order they ran. */ -export function formatPhaseBar(timings: PhaseTiming[], columns = process.stdout.columns || 80): string { +export function formatPhaseTable(timings: PhaseTiming[]): string { const shown = timings.filter(timing => timing.duration >= 10) - if (!shown.length) { - return '' - } - if (styleText('red', ' ') === ' ') { - return formatPhaseBreakdown(shown) - } const total = shown.reduce((sum, timing) => sum + timing.duration, 0) - // Every phase keeps at least one cell so its colour is on the bar; the - // rounding is settled on the largest segment. - const cells = shown.map(timing => Math.max(1, Math.round(timing.duration / total * PHASE_BAR_WIDTH))) - const largest = cells.indexOf(Math.max(...cells)) - cells[largest]! += PHASE_BAR_WIDTH - cells.reduce((sum, count) => sum + count, 0) - - const bar = shown.map((_, index) => styleText(PHASE_COLORS[index % PHASE_COLORS.length]!, '\u2588'.repeat(cells[index]!))).join('') - const entries = shown.map((timing, index) => ({ - text: `\u25A0 ${timing.phase} ${formatDuration(timing.duration)}`, - styled: `${styleText(PHASE_COLORS[index % PHASE_COLORS.length]!, '\u25A0')} ${timing.phase} ${styleText('dim', formatDuration(timing.duration))}`, - })) - - // Wrap the legend between entries rather than letting the terminal split one. - const width = Math.max(columns - GUTTER_WIDTH, 20) - const legend: string[] = [] - let line = '' - let length = 0 - for (const entry of entries) { - if (length && length + 2 + entry.text.length > width) { - legend.push(line) - line = '' - length = 0 - } - line += length ? ` ${entry.styled}` : entry.styled - length += (length ? 2 : 0) + entry.text.length - } - legend.push(line) - return [bar, ...legend].join('\n') + const nameWidth = Math.max(...shown.map(timing => timing.phase.length)) + const durations = shown.map(timing => formatDuration(timing.duration)) + const durationWidth = Math.max(...durations.map(duration => duration.length)) + return shown.map((timing, index) => { + const share = timing.duration / total + const filled = Math.max(1, Math.round(share * PHASE_BAR_WIDTH)) + const bar = styleText('cyan', '█'.repeat(filled)) + styleText('dim', '░'.repeat(PHASE_BAR_WIDTH - filled)) + const percent = `${Math.round(share * 100)}%`.padStart(4) + return `${timing.phase.padEnd(nameWidth)} ${durations[index]!.padStart(durationWidth)} ${bar} ${styleText('dim', percent)}` + }).join('\n') } /** diff --git a/packages/nuxt-cli/test/unit/phase-reporter.spec.ts b/packages/nuxt-cli/test/unit/phase-reporter.spec.ts index edbfb69fa..221e1b229 100644 --- a/packages/nuxt-cli/test/unit/phase-reporter.spec.ts +++ b/packages/nuxt-cli/test/unit/phase-reporter.spec.ts @@ -15,7 +15,7 @@ vi.mock('std-env', async importOriginal => ({ process.env.FORCE_COLOR = '3' -const { createPhaseReporter, formatPhaseBar, formatSummary, isAnimationSupported } = await import('../../src/utils/phase-reporter') +const { createPhaseReporter, formatPhaseTable, formatSummary, isAnimationSupported } = await import('../../src/utils/phase-reporter') function snapshot(overrides: Partial = {}): ProgressSnapshot { return { @@ -384,39 +384,19 @@ describe('phase reporter', () => { }) }) -describe('formatPhaseBar', () => { - const timings = [ - { phase: 'config', message: '', duration: 1000 }, - { phase: 'types', message: '', duration: 5 }, - { phase: 'bundle (client)', message: '', duration: 2900 }, - { phase: 'prerender', message: '', duration: 20 }, - ] - - it('splits a 40-cell bar into one segment per phase, sized by its share', () => { - const [bar, ...legend] = formatPhaseBar(timings, 120).split('\n') +describe('formatPhaseTable', () => { + it('lines phases up with a bar for their share of the phases shown', () => { + const table = formatPhaseTable([ + { phase: 'config', message: '', duration: 1000 }, + { phase: 'types', message: '', duration: 5 }, + { phase: 'bundle (client)', message: '', duration: 2900 }, + { phase: 'prerender', message: '', duration: 100 }, + ]) // `types` is too quick to list, so it is left out of the total as well. - // Of 3.92s: config rounds to 10 cells and bundle (client) to 30; prerender - // rounds to none but keeps one, which the largest segment gives back. - const segments = bar!.split('\u001B[').filter(part => part.includes('█')).map(part => [part.slice(0, part.indexOf('m')), part.split('█').length - 1]) - expect(segments).toEqual([['34', 10], ['36', 29], ['32', 1]]) - expect(legend.map(line => stripVTControlCharacters(line))).toEqual(['■ config 1.00s ■ bundle (client) 2.90s ■ prerender 20ms']) - }) - - it('wraps the legend between entries', () => { - const legend = formatPhaseBar(timings, 40).split('\n').slice(1).map(line => stripVTControlCharacters(line)) - expect(legend).toEqual(['■ config 1.00s', '■ bundle (client) 2.90s', '■ prerender 20ms']) - }) - - it('falls back to one line without colours', () => { - process.env.NO_COLOR = '1' - const previous = process.env.FORCE_COLOR - delete process.env.FORCE_COLOR - try { - expect(formatPhaseBar(timings, 120)).toBe('config 1.00s · bundle (client) 2.90s · prerender 20ms') - } - finally { - delete process.env.NO_COLOR - process.env.FORCE_COLOR = previous - } + expect(stripVTControlCharacters(table).split('\n')).toEqual([ + 'config 1.00s █████░░░░░░░░░░░░░░░ 25%', + 'bundle (client) 2.90s ███████████████░░░░░ 73%', + 'prerender 100ms █░░░░░░░░░░░░░░░░░░░ 3%', + ]) }) }) From 703ce7d3f542bb637528f5977292912afe87152d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 23:52:33 +0000 Subject: [PATCH 37/38] fix(build): only offer any static host for the generic static preset A provider preset such as vercel-static lays its output out for that provider, so generate now ends on the preset's deploy command, or names the provider when the preset has none. Amp-Thread-ID: https://ampcode.com/threads/T-01a1ba1d-392b-7447-9cc3-9587ae9be465 --- packages/nuxt-cli/src/commands/build.ts | 2 +- packages/nuxt-cli/src/utils/server-output.ts | 18 +++++++++++++ .../test/unit/utils/server-output.spec.ts | 25 +++++++++++++++++++ 3 files changed, 44 insertions(+), 1 deletion(-) diff --git a/packages/nuxt-cli/src/commands/build.ts b/packages/nuxt-cli/src/commands/build.ts index 3532b788b..797c251a2 100644 --- a/packages/nuxt-cli/src/commands/build.ts +++ b/packages/nuxt-cli/src/commands/build.ts @@ -166,7 +166,7 @@ export default defineCommand({ const total = `Build complete in ${styleText('cyan', formatDuration(Date.now() - start))}` const complete = breakdown ? `${total}\n${verbose ? breakdown : styleText('dim', breakdown)}` : total const next = ctx.args.prerender - ? [`You can now deploy ${styleText('cyan', serverBuild.publicDir ? relative(process.cwd(), serverBuild.publicDir) : '.output/public')} to any static hosting`] + ? serverOutput.staticCommands(serverBuild.publicDir ? relative(process.cwd(), serverBuild.publicDir) : '.output/public') : serverOutput.commands() if (next.length) { logger.success(complete) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index e593ff015..2f17d87da 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -32,6 +32,8 @@ export interface ServerOutputReport { summary: (timings: PhaseTiming[]) => string | undefined /** How to preview and deploy what was built: no preview when no server was written. */ commands: () => string[] + /** What to do with a prerendered build: where it can go, or the provider's own deploy command. */ + staticCommands: (publicDir: string) => string[] } interface ServerOutputOptions { @@ -80,6 +82,8 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) const routes: PrerenderRoute[] = [] let deploy: string | undefined let isStatic = false + let preset: string | undefined + let outputDir: string | undefined const measure = async (dir: string | undefined) => { size = dir ? await directorySize(dir).catch(() => undefined) : undefined @@ -181,6 +185,8 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) }) nitro.hooks.hook('compiled', async () => { isStatic = !!nitro.options.static + preset = nitro.options.preset + outputDir = nitro.options.output.dir deploy = nitro.options.commands?.deploy ? resolveDeployCommand(nitro) : undefined await measure(nitro.options.output.serverDir) }) @@ -218,6 +224,18 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) } return commands }, + staticCommands(publicDir) { + // Only the generic preset writes plain files that any static host serves. + if (!preset || preset === 'static') { + return [`You can now deploy ${styleText('cyan', publicDir)} to any static hosting`] + } + // A provider preset lays its output out for that provider. + if (deploy) { + return [`You can deploy this build using ${styleText('cyan', deploy)}`] + } + const dir = outputDir ? relative(process.cwd(), outputDir) || '.' : publicDir + return [`You can now deploy ${styleText('cyan', dir)} to ${styleText('cyan', preset)}`] + }, } } diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index a8177bd48..cfe116514 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -243,6 +243,31 @@ describe('quietServerOutput', () => { }) }) +describe('static build outro', () => { + async function staticBuild(options: Record) { + const { nuxt, hooks } = createNuxt() + const report = quietServerOutput(nuxt as any) + const nitroHooks = createHooks() + const nitro = { options: { static: true, output: { serverDir: '/missing', dir: join(process.cwd(), 'dist') }, ...options }, hooks: nitroHooks } + await hooks.call('nitro:init', nitro) + await nitroHooks.call('compiled', nitro) + return report.staticCommands('.output/public').map(stripAnsi) + } + + it('offers any static host only for the generic preset', async () => { + expect(await staticBuild({ preset: 'static' })).toEqual(['You can now deploy .output/public to any static hosting']) + }) + + it('gives a provider preset its own deploy command', async () => { + expect(await staticBuild({ preset: 'vercel-static', commands: { deploy: 'npx vercel deploy --prebuilt' } })) + .toEqual(['You can deploy this build using npx vercel deploy --prebuilt']) + }) + + it('names the provider when its preset has no deploy command', async () => { + expect(await staticBuild({ preset: 'netlify-static' })).toEqual(['You can now deploy dist to netlify-static']) + }) +}) + describe('formatBytes', () => { it('uses decimal units like Vite and Nitro', () => { expect([formatBytes(999), formatBytes(1000), formatBytes(2_454_000)]).toEqual(['999 B', '1.00 kB', '2.45 MB']) From 21b7d005f29cf9ae61a7eb94eebd689594550640 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Thu, 12 Nov 2026 23:59:44 +0000 Subject: [PATCH 38/38] fix(build): leave Vite's native reporter out of server environments Vite 8's reporter writes its progress lines straight to the terminal, past the logger, so muting the logger left 'N modules transformed.' and 'computing gzip size...' for every server environment on Nuxt 5 and @nuxt/vite-server. --- packages/nuxt-cli/src/utils/server-output.ts | 12 ++++++++++++ .../test/unit/utils/server-output.spec.ts | 17 ++++++++++++++--- 2 files changed, 26 insertions(+), 3 deletions(-) diff --git a/packages/nuxt-cli/src/utils/server-output.ts b/packages/nuxt-cli/src/utils/server-output.ts index 2f17d87da..d898e8fa6 100644 --- a/packages/nuxt-cli/src/utils/server-output.ts +++ b/packages/nuxt-cli/src/utils/server-output.ts @@ -21,6 +21,9 @@ const PRERENDER_ROUTE_LIMIT = 20 const VITE_PLUGIN_NAME = 'nuxi:server-output' +/** Vite 8's build reporter, created once per environment. */ +const VITE_REPORTER_PLUGIN = 'native:reporter' + /** The line Vite opens each environment's build with, e.g. `vite v8.3.5 building ssr environment for production...`. */ const ENVIRONMENT_BUILD_RE = /building (\S+) environment for/ @@ -50,6 +53,7 @@ interface ViteLogger { interface ResolvedViteConfig { logger: ViteLogger environments?: Record + plugins: Array<{ name?: string, applyToEnvironment?: (environment: { config: { consumer?: string } }) => unknown }> } interface ViteBuildContext { @@ -135,6 +139,14 @@ export function quietServerOutput(nuxt: Nuxt, options: ServerOutputOptions = {}) if (!quietVite) { return } + // Vite's reporter is native and writes its progress lines (`N modules + // transformed.`, `computing gzip size...`) straight to the terminal, past + // the logger, so it is left out of server environments altogether. + const reporter = config.plugins.find(plugin => plugin.name === VITE_REPORTER_PLUGIN) + const applyToEnvironment = reporter?.applyToEnvironment + if (reporter && applyToEnvironment) { + reporter.applyToEnvironment = environment => environment.config.consumer === 'server' ? false : applyToEnvironment(environment) + } // Vite reports each environment through the one logger, at a single log // level. Muting its info messages while a server environment builds keeps // the client's file list and every warning. diff --git a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts index cfe116514..a4bc4d161 100644 --- a/packages/nuxt-cli/test/unit/utils/server-output.spec.ts +++ b/packages/nuxt-cli/test/unit/utils/server-output.spec.ts @@ -50,8 +50,10 @@ async function resolveVitePlugin(hooks: ReturnType) { const plugin = config.plugins[0] const printed: string[] = [] const logger = { info: (message: string) => void printed.push(message) } - plugin.configResolved({ logger, environments: { client: { consumer: 'client' }, ssr: { consumer: 'server' }, nitro: { consumer: 'server' } } }) - return { plugin, logger, printed } + // Vite's reporter, which Vite builds per environment. + const reporter = { name: 'native:reporter', applyToEnvironment: (_environment: { config: { consumer: string } }) => ({ name: 'builtin:vite-reporter' }) as unknown } + plugin.configResolved({ logger, plugins: [reporter], environments: { client: { consumer: 'client' }, ssr: { consumer: 'server' }, nitro: { consumer: 'server' } } }) + return { plugin, logger, printed, reporter } } describe('quietServerOutput', () => { @@ -65,6 +67,15 @@ describe('quietServerOutput', () => { expect(nitroConfig.logLevel).toBe(1) }) + it('leaves Vite\'s native reporter out of server environments', async () => { + const { nuxt, hooks } = createNuxt() + quietServerOutput(nuxt as any) + const { reporter } = await resolveVitePlugin(hooks) + + expect(reporter.applyToEnvironment({ config: { consumer: 'client' } })).toEqual({ name: 'builtin:vite-reporter' }) + expect(reporter.applyToEnvironment({ config: { consumer: 'server' } })).toBe(false) + }) + it('keeps Vite\'s output for the client environment only', async () => { const { nuxt, hooks } = createNuxt() quietServerOutput(nuxt as any) @@ -95,7 +106,7 @@ describe('quietServerOutput', () => { const legacy = { plugins: [] as any[] } await hooks.call('vite:extendConfig', legacy, { isClient: false, isServer: true }) - legacy.plugins[0].configResolved({ logger: { info: () => {} }, build: { ssr: true } }) + legacy.plugins[0].configResolved({ logger: { info: () => {} }, plugins: [], build: { ssr: true } }) legacy.plugins[0].buildStart.call({}) expect(started).toEqual([{ name: 'nitro', consumer: 'server' }, { name: undefined, consumer: 'server' }])