From b4e28c6170f263aa629e39b189afb572ef3eaa12 Mon Sep 17 00:00:00 2001 From: Anthony Fu Date: Tue, 14 Jan 2025 20:46:19 +0800 Subject: [PATCH] docs: update --- packages/schema/src/config/common.ts | 9 --------- packages/schema/src/types/debug.ts | 7 +++++++ 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/packages/schema/src/config/common.ts b/packages/schema/src/config/common.ts index ff464939eb..38d64bcccd 100644 --- a/packages/schema/src/config/common.ts +++ b/packages/schema/src/config/common.ts @@ -262,15 +262,6 @@ export default defineUntypedSchema({ * logs hook arguments as well in the browser. * * You can also set this to an object to enable specific debug options. - * ```js - * { - * log: true, // Log additional information on terminal - * hooks: true, // Log hooks calls and timings - * nitro: true, // Set nitro debug mode - * browser: true, // Log additional information in browser console - * prod: true // Log additional information in production mode (hydration mismatch, etc.) - * } - * ``` * * @type {boolean | (typeof import('../src/types/debug').NuxtDebugOptions) | undefined} */ diff --git a/packages/schema/src/types/debug.ts b/packages/schema/src/types/debug.ts index d21a6c3905..9ea76b7fc0 100644 --- a/packages/schema/src/types/debug.ts +++ b/packages/schema/src/types/debug.ts @@ -1,12 +1,19 @@ import type { NitroOptions } from 'nitro/types' export interface NuxtDebugOptions { + /** Debug for Nuxt templates */ templates?: boolean + /** Debug for modules setup timings */ modules?: boolean + /** Debug for file watchers */ watchers?: boolean + /** Debug options for Nitro */ nitro?: NitroOptions['debug'] + /** Debug for production hydration mismatch */ hydration?: boolean + /** Debug for Vue Router */ router?: boolean + /** Debug for hooks, can be set to `true` or an object with `server` and `client` keys */ hooks?: boolean | { server?: boolean client?: boolean