@nuxt/docs-nightly 4.5.1-29752449.30d24817 → 4.5.2-2610052030-052d82e

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (214) hide show
  1. package/1.getting-started/01.introduction.md +8 -8
  2. package/1.getting-started/02.installation.md +2 -4
  3. package/1.getting-started/03.configuration.md +16 -16
  4. package/1.getting-started/04.views.md +8 -8
  5. package/1.getting-started/05.assets.md +10 -10
  6. package/1.getting-started/06.styling.md +10 -10
  7. package/1.getting-started/07.routing.md +15 -15
  8. package/1.getting-started/08.seo-meta.md +15 -15
  9. package/1.getting-started/09.transitions.md +10 -10
  10. package/1.getting-started/10.data-fetching.md +61 -47
  11. package/1.getting-started/11.state-management.md +11 -11
  12. package/1.getting-started/12.error-handling.md +20 -18
  13. package/1.getting-started/13.server.md +7 -7
  14. package/1.getting-started/14.layers.md +6 -6
  15. package/1.getting-started/15.prerendering.md +22 -28
  16. package/1.getting-started/16.deployment.md +22 -6
  17. package/1.getting-started/17.testing.md +200 -21
  18. package/1.getting-started/18.upgrade.md +78 -278
  19. package/2.directory-structure/0.nuxt.md +2 -2
  20. package/2.directory-structure/0.output.md +3 -3
  21. package/2.directory-structure/1.app/1.assets.md +3 -3
  22. package/2.directory-structure/1.app/1.components.md +26 -109
  23. package/2.directory-structure/1.app/1.composables.md +5 -5
  24. package/2.directory-structure/1.app/1.layouts.md +10 -10
  25. package/2.directory-structure/1.app/1.middleware.md +14 -10
  26. package/2.directory-structure/1.app/1.pages.md +25 -20
  27. package/2.directory-structure/1.app/1.plugins.md +7 -7
  28. package/2.directory-structure/1.app/1.utils.md +9 -5
  29. package/2.directory-structure/1.app/3.app-config.md +7 -7
  30. package/2.directory-structure/1.app/3.app.md +6 -6
  31. package/2.directory-structure/1.app/3.error.md +1 -1
  32. package/2.directory-structure/1.content.md +1 -1
  33. package/2.directory-structure/1.layers.md +13 -13
  34. package/2.directory-structure/1.modules.md +3 -3
  35. package/2.directory-structure/1.node_modules.md +1 -1
  36. package/2.directory-structure/1.server.md +33 -14
  37. package/2.directory-structure/1.shared.md +7 -5
  38. package/2.directory-structure/1.test.md +25 -0
  39. package/2.directory-structure/2.env.md +7 -7
  40. package/2.directory-structure/2.nuxtignore.md +3 -3
  41. package/2.directory-structure/2.nuxtrc.md +3 -3
  42. package/2.directory-structure/3.nuxt-config.md +2 -2
  43. package/2.directory-structure/3.tsconfig.md +21 -11
  44. package/2.directory-structure/index.md +29 -25
  45. package/3.guide/0.index.md +6 -6
  46. package/3.guide/1.concepts/1.rendering.md +76 -12
  47. package/3.guide/1.concepts/10.vuejs-development.md +73 -8
  48. package/3.guide/1.concepts/2.nuxt-lifecycle.md +18 -18
  49. package/3.guide/1.concepts/3.auto-imports.md +11 -11
  50. package/3.guide/1.concepts/4.server-engine.md +6 -6
  51. package/3.guide/1.concepts/5.modules.md +4 -4
  52. package/3.guide/1.concepts/6.server-components.md +198 -0
  53. package/3.guide/1.concepts/7.esm.md +5 -5
  54. package/3.guide/1.concepts/8.typescript.md +9 -9
  55. package/3.guide/2.best-practices/accessibility.md +155 -0
  56. package/3.guide/2.best-practices/hydration.md +5 -5
  57. package/3.guide/2.best-practices/performance.md +13 -9
  58. package/3.guide/3.ai/1.mcp.md +104 -19
  59. package/3.guide/4.modules/2.module-anatomy.md +5 -5
  60. package/3.guide/4.modules/3.recipes-basics.md +8 -8
  61. package/3.guide/4.modules/4.module-dependencies.md +1 -1
  62. package/3.guide/4.modules/5.recipes-advanced.md +6 -8
  63. package/3.guide/4.modules/6.testing.md +2 -2
  64. package/3.guide/4.modules/7.best-practices.md +2 -2
  65. package/3.guide/4.modules/9.server-compatibility.md +215 -0
  66. package/3.guide/4.modules/index.md +9 -9
  67. package/3.guide/5.recipes/1.custom-routing.md +15 -11
  68. package/3.guide/5.recipes/2.vite-plugin.md +3 -3
  69. package/3.guide/5.recipes/3.custom-usefetch.md +5 -5
  70. package/3.guide/5.recipes/4.sessions-and-authentication.md +2 -2
  71. package/3.guide/5.recipes/5.mostly-static-sites.md +127 -0
  72. package/3.guide/6.going-further/1.events.md +1 -1
  73. package/3.guide/6.going-further/1.experimental-features.md +254 -22
  74. package/3.guide/6.going-further/1.features.md +42 -6
  75. package/3.guide/6.going-further/1.internals.md +10 -10
  76. package/3.guide/6.going-further/10.runtime-config.md +28 -6
  77. package/3.guide/6.going-further/11.nightly-release-channel.md +1 -1
  78. package/3.guide/6.going-further/2.hooks.md +6 -6
  79. package/3.guide/6.going-further/4.kit.md +4 -4
  80. package/3.guide/6.going-further/5.server-imports.md +221 -0
  81. package/3.guide/6.going-further/6.nuxt-app.md +7 -7
  82. package/3.guide/6.going-further/7.layers.md +13 -13
  83. package/3.guide/6.going-further/8.builders.md +38 -14
  84. package/4.api/1.components/1.nuxt-client-fallback.md +1 -1
  85. package/4.api/1.components/10.nuxt-picture.md +1 -1
  86. package/4.api/1.components/11.teleports.md +1 -1
  87. package/4.api/1.components/12.nuxt-route-announcer.md +5 -3
  88. package/4.api/1.components/14.nuxt-announcer.md +3 -3
  89. package/4.api/1.components/2.nuxt-page.md +5 -5
  90. package/4.api/1.components/3.nuxt-layout.md +8 -8
  91. package/4.api/1.components/4.nuxt-link.md +6 -4
  92. package/4.api/1.components/5.nuxt-loading-indicator.md +3 -3
  93. package/4.api/1.components/6.nuxt-error-boundary.md +1 -1
  94. package/4.api/1.components/8.nuxt-island.md +5 -5
  95. package/4.api/2.composables/create-use-async-data.md +51 -8
  96. package/4.api/2.composables/create-use-fetch.md +126 -9
  97. package/4.api/2.composables/use-announcer.md +3 -3
  98. package/4.api/2.composables/use-app-config.md +1 -1
  99. package/4.api/2.composables/use-async-data.md +19 -11
  100. package/4.api/2.composables/use-cookie.md +22 -6
  101. package/4.api/2.composables/use-error.md +1 -1
  102. package/4.api/2.composables/use-fetch.md +14 -10
  103. package/4.api/2.composables/use-head-safe.md +2 -2
  104. package/4.api/2.composables/use-head.md +2 -2
  105. package/4.api/2.composables/use-hydration.md +1 -1
  106. package/4.api/2.composables/use-layout.md +1 -1
  107. package/4.api/2.composables/use-lazy-async-data.md +8 -8
  108. package/4.api/2.composables/use-lazy-fetch.md +11 -11
  109. package/4.api/2.composables/use-loading-indicator.md +2 -2
  110. package/4.api/2.composables/use-nuxt-app.md +13 -13
  111. package/4.api/2.composables/use-nuxt-data.md +1 -1
  112. package/4.api/2.composables/use-preview-mode.md +3 -3
  113. package/4.api/2.composables/use-request-event.md +29 -3
  114. package/4.api/2.composables/use-request-fetch.md +2 -2
  115. package/4.api/2.composables/use-request-header.md +1 -1
  116. package/4.api/2.composables/use-request-headers.md +1 -1
  117. package/4.api/2.composables/use-request-url.md +1 -1
  118. package/4.api/2.composables/use-response-header.md +2 -2
  119. package/4.api/2.composables/use-route-announcer.md +4 -2
  120. package/4.api/2.composables/use-route.md +2 -2
  121. package/4.api/2.composables/use-router.md +5 -5
  122. package/4.api/2.composables/use-runtime-config.md +5 -5
  123. package/4.api/2.composables/use-runtime-hook.md +1 -1
  124. package/4.api/2.composables/use-seo-meta.md +3 -3
  125. package/4.api/2.composables/use-server-seo-meta.md +5 -5
  126. package/4.api/2.composables/use-state.md +4 -4
  127. package/4.api/3.utils/$fetch.md +5 -5
  128. package/4.api/3.utils/abort-navigation.md +1 -1
  129. package/4.api/3.utils/add-route-middleware.md +2 -2
  130. package/4.api/3.utils/call-once.md +3 -3
  131. package/4.api/3.utils/clear-error.md +2 -2
  132. package/4.api/3.utils/clear-nuxt-data.md +1 -1
  133. package/4.api/3.utils/clear-nuxt-state.md +2 -2
  134. package/4.api/3.utils/create-error.md +19 -1
  135. package/4.api/3.utils/define-nuxt-plugin.md +2 -2
  136. package/4.api/3.utils/define-nuxt-route-middleware.md +3 -3
  137. package/4.api/3.utils/define-page-meta.md +12 -12
  138. package/4.api/3.utils/define-route-rules.md +4 -4
  139. package/4.api/3.utils/define-use-async-data-addon.md +57 -0
  140. package/4.api/3.utils/define-use-fetch-addon.md +168 -0
  141. package/4.api/3.utils/navigate-to.md +6 -2
  142. package/4.api/3.utils/prefetch-components.md +1 -1
  143. package/4.api/3.utils/preload-route-components.md +2 -2
  144. package/4.api/3.utils/prerender-routes.md +3 -3
  145. package/4.api/3.utils/refresh-cookie.md +1 -1
  146. package/4.api/3.utils/refresh-nuxt-data.md +3 -3
  147. package/4.api/3.utils/reload-nuxt-app.md +1 -1
  148. package/4.api/3.utils/set-page-layout.md +1 -1
  149. package/4.api/3.utils/set-response-status.md +2 -2
  150. package/4.api/3.utils/show-error.md +3 -3
  151. package/4.api/3.utils/update-app-config.md +2 -2
  152. package/4.api/4.commands/README.md +9 -0
  153. package/4.api/5.kit/1.modules.md +3 -3
  154. package/4.api/5.kit/10.runtime-config.md +1 -1
  155. package/4.api/5.kit/10.templates.md +42 -0
  156. package/4.api/5.kit/12.nitro.md +59 -18
  157. package/4.api/5.kit/14.logging.md +56 -2
  158. package/4.api/5.kit/15.builder.md +1 -1
  159. package/4.api/5.kit/18.dependencies.md +90 -0
  160. package/4.api/5.kit/2.programmatic.md +78 -1
  161. package/4.api/5.kit/3.compatibility.md +2 -2
  162. package/4.api/5.kit/4.autoimports.md +13 -13
  163. package/4.api/5.kit/5.components.md +3 -3
  164. package/4.api/5.kit/6.context.md +2 -2
  165. package/4.api/5.kit/7.pages.md +35 -4
  166. package/4.api/5.kit/8.layout.md +1 -1
  167. package/4.api/6.advanced/1.hooks.md +6 -3
  168. package/4.api/6.nuxt-config.md +44 -21
  169. package/4.api/index.md +7 -7
  170. package/5.community/2.getting-help.md +1 -1
  171. package/5.community/3.reporting-bugs.md +1 -1
  172. package/5.community/4.contribution.md +14 -12
  173. package/5.community/5.framework-contribution.md +4 -4
  174. package/5.community/6.roadmap.md +6 -6
  175. package/6.bridge/1.overview.md +12 -12
  176. package/6.bridge/2.typescript.md +1 -1
  177. package/6.bridge/3.bridge-composition-api.md +6 -6
  178. package/6.bridge/4.plugins-and-middleware.md +4 -4
  179. package/6.bridge/5.nuxt3-compatible-api.md +9 -9
  180. package/6.bridge/6.meta.md +5 -5
  181. package/6.bridge/7.runtime-config.md +1 -1
  182. package/6.bridge/8.nitro.md +1 -1
  183. package/6.bridge/9.vite.md +1 -1
  184. package/7.migration/1.overview.md +2 -2
  185. package/7.migration/10.bundling.md +1 -1
  186. package/7.migration/11.server.md +3 -3
  187. package/7.migration/2.configuration.md +6 -6
  188. package/7.migration/20.module-authors.md +7 -7
  189. package/7.migration/3.auto-imports.md +3 -3
  190. package/7.migration/4.meta.md +4 -4
  191. package/7.migration/5.plugins-and-middleware.md +3 -3
  192. package/7.migration/6.pages-and-layouts.md +13 -13
  193. package/7.migration/7.component-options.md +15 -15
  194. package/7.migration/8.runtime-config.md +4 -4
  195. package/README.md +1 -1
  196. package/errors/e8007.md +28 -0
  197. package/package.json +2 -2
  198. package/4.api/4.commands/.navigation.yml +0 -3
  199. package/4.api/4.commands/add.md +0 -112
  200. package/4.api/4.commands/analyze.md +0 -42
  201. package/4.api/4.commands/build-module.md +0 -42
  202. package/4.api/4.commands/build.md +0 -48
  203. package/4.api/4.commands/cleanup.md +0 -38
  204. package/4.api/4.commands/dev.md +0 -61
  205. package/4.api/4.commands/devtools.md +0 -38
  206. package/4.api/4.commands/generate.md +0 -43
  207. package/4.api/4.commands/info.md +0 -33
  208. package/4.api/4.commands/init.md +0 -50
  209. package/4.api/4.commands/module.md +0 -84
  210. package/4.api/4.commands/prepare.md +0 -41
  211. package/4.api/4.commands/preview.md +0 -44
  212. package/4.api/4.commands/test.md +0 -40
  213. package/4.api/4.commands/typecheck.md +0 -44
  214. package/4.api/4.commands/upgrade.md +0 -37
@@ -12,7 +12,7 @@ Nuxt offers several built-in features that help you optimize performance of your
12
12
 
13
13
  ### Links
14
14
 
15
- [`<NuxtLink>`](/docs/4.x/api/components/nuxt-link) is a drop-in replacement for both Vue Router's `<RouterLink>` component and HTML's `<a>` tag. It intelligently determines whether the link is internal or external and renders it accordingly with available optimizations (prefetching, default attributes, etc.)
15
+ [`<NuxtLink>`](/docs/api/components/nuxt-link) is a drop-in replacement for both Vue Router's `<RouterLink>` component and HTML's `<a>` tag. It intelligently determines whether the link is internal or external and renders it accordingly with available optimizations (prefetching, default attributes, etc.)
16
16
 
17
17
  ```html
18
18
  <template>
@@ -42,7 +42,7 @@ export default defineNuxtConfig({
42
42
  })
43
43
  ```
44
44
 
45
- :read-more{title="NuxtLink" to="/docs/4.x/api/components/nuxt-link"}
45
+ :read-more{title="NuxtLink" to="/docs/api/components/nuxt-link"}
46
46
 
47
47
  ### Hybrid Rendering
48
48
 
@@ -71,7 +71,7 @@ export default defineNuxtConfig({
71
71
 
72
72
  Nuxt server will automatically register corresponding middleware and wrap routes with cache handlers using Nitro caching layer.
73
73
 
74
- :read-more{title="Hybrid rendering" to="/docs/4.x/guide/concepts/rendering#hybrid-rendering"}
74
+ :read-more{title="Hybrid rendering" to="/docs/guide/concepts/rendering#hybrid-rendering"}
75
75
 
76
76
  ### Lazy Loading Components
77
77
 
@@ -93,7 +93,7 @@ const show = ref(false)
93
93
 
94
94
  By using the Lazy prefix you can delay loading the component code until the right moment, which can be helpful for optimizing your JavaScript bundle size.
95
95
 
96
- :read-more{title="Lazy loading components" to="/docs/4.x/directory-structure/app/components#dynamic-imports"}
96
+ :read-more{title="Lazy loading components" to="/docs/directory-structure/app/components#dynamic-imports"}
97
97
 
98
98
  ### Lazy Hydration
99
99
 
@@ -109,13 +109,17 @@ It is not always necessary to hydrate (or make interactive) all the components o
109
109
 
110
110
  To optimize your app, you may want to delay the hydration of some components until they're visible, or until the browser is done with more important tasks.
111
111
 
112
- :read-more{title="Lazy hydration" to="/docs/4.x/directory-structure/app/components#delayed-or-lazy-hydration"}
112
+ :read-more{title="Lazy hydration" to="/docs/directory-structure/app/components#delayed-or-lazy-hydration"}
113
+
114
+ For content and marketing sites that need little or no client-side interactivity, you can go further and combine prerendering, the `noScripts` route rule, [server components](/docs/guide/concepts/server-components) and lazy hydration to ship near-zero JavaScript.
115
+
116
+ :read-more{title="Mostly-static sites" to="/docs/guide/recipes/mostly-static-sites"}
113
117
 
114
118
  ### Fetching data
115
119
 
116
- To avoid fetching same data twice (once on the server and once on client) Nuxt provides [`useFetch`](/docs/4.x/api/composables/use-fetch) and [`useAsyncData`](/docs/4.x/api/composables/use-async-data). They ensure that if an API call is made on the server, the data is forwarded to the client in the payload instead of being fetched again.
120
+ To avoid fetching same data twice (once on the server and once on client) Nuxt provides [`useFetch`](/docs/api/composables/use-fetch) and [`useAsyncData`](/docs/api/composables/use-async-data). They ensure that if an API call is made on the server, the data is forwarded to the client in the payload instead of being fetched again.
117
121
 
118
- :read-more{title="Data fetching" to="/docs/4.x/getting-started/data-fetching"}
122
+ :read-more{title="Data fetching" to="/docs/getting-started/data-fetching"}
119
123
 
120
124
  ## Core Nuxt Modules
121
125
 
@@ -129,7 +133,7 @@ In Nuxt we can use [Nuxt Image](https://image.nuxt.com/) module that is a plug-a
129
133
 
130
134
  :video-accordion{title="Watch the video by LearnVue about Nuxt Image" videoId="_UBff2eqGY0"}
131
135
 
132
- [`<NuxtImg>`](/docs/4.x/api/components/nuxt-img) is a drop-in replacement for the native `<img>` tag that comes with following enhancements:
136
+ [`<NuxtImg>`](/docs/api/components/nuxt-img) is a drop-in replacement for the native `<img>` tag that comes with following enhancements:
133
137
 
134
138
  * Uses built-in provider to optimize local and remote images
135
139
  * Converts `src` to provider optimized URLs with modern formats such as WebP or Avif
@@ -218,7 +222,7 @@ To improve performance, we need to first know how to measure it, starting with m
218
222
 
219
223
  ### Nuxi Analyze
220
224
 
221
- [This](/docs/4.x/api/commands/analyze) command of `nuxt` allows you to analyze the production bundle of your Nuxt application. It leverages `vite-bundle-visualizer` (similar to `webpack-bundle-analyzer`) to generate a visual representation of your application's bundle, making it easier to identify which components take up the most space.
225
+ [This](/docs/api/commands/analyze) command of `nuxt` allows you to analyze the production bundle of your Nuxt application. It leverages `vite-bundle-visualizer` (similar to `webpack-bundle-analyzer`) to generate a visual representation of your application's bundle, making it easier to identify which components take up the most space.
222
226
 
223
227
  When you see a large block in the visualization, it often signals an opportunity for optimization—whether by splitting it into smaller parts, implementing lazy loading, or replacing it with a more efficient alternative, especially for third-party libraries.
224
228
 
@@ -26,27 +26,50 @@ The Nuxt MCP server provides the following tools organized by category:
26
26
 
27
27
  ### Documentation
28
28
 
29
- - **`list_documentation_pages`**: Lists all available Nuxt documentation pages with their categories and basic information. Supports version filtering (3.x, 4.x, or all)
30
- - **`get_documentation_page`**: Retrieves documentation page content and details by path
31
- - **`get_getting_started_guide`**: Gets the getting started guide for a specific Nuxt version
29
+ - **`list-documentation-pages`**: Lists all available Nuxt documentation pages with their categories and basic information. Supports version filtering (3.x, 4.x, 5.x, or all)
30
+ - **`get-documentation-page`**: Retrieves documentation page content and details by path
31
+ - **`get-getting-started-guide`**: Gets the getting started guide for a specific Nuxt version
32
32
 
33
33
  ### Blog
34
34
 
35
- - **`list_blog_posts`**: Lists all Nuxt blog posts with metadata including dates, categories, and tags
36
- - **`get_blog_post`**: Retrieves blog post content and details by path
35
+ - **`list-blog-posts`**: Lists all Nuxt blog posts with metadata including dates, categories, and tags
36
+ - **`get-blog-post`**: Retrieves blog post content and details by path
37
37
 
38
38
  ### Deployment
39
39
 
40
- - **`list_deploy_providers`**: Lists all deployment providers and hosting platforms for Nuxt applications
41
- - **`get_deploy_provider`**: Retrieves deployment provider details and instructions by path
40
+ - **`list-deploy-providers`**: Lists all deployment providers and hosting platforms for Nuxt applications
41
+ - **`get-deploy-provider`**: Retrieves deployment provider details and instructions by path
42
+
43
+ ### Modules
44
+
45
+ - **`list-modules`**: Lists all available Nuxt modules with optional filtering and sorting by downloads, stars, or date
46
+ - **`get-module`**: Retrieves complete details about a specific module including README, compatibility, maintainers, and stats
47
+
48
+ ### Changelog
49
+
50
+ - **`get-changelog`**: Retrieves the latest releases from Nuxt core and official modules
51
+
52
+ ## Limit Available Tools
53
+
54
+ Set the optional `X-MCP-Tools` HTTP header to a comma-separated list of tool names to expose only the tools your assistant needs. This reduces the tool context sent to your assistant.
55
+
56
+ Use the exact kebab-case MCP tool names returned by the server, for example:
57
+
58
+ ```json
59
+ {
60
+ "X-MCP-Tools": "list-documentation-pages,get-documentation-page"
61
+ }
62
+ ```
63
+
64
+ No header exposes all tools, an empty header exposes no tools, and an unknown tool name returns a configuration error.
42
65
 
43
66
  ## Prompts
44
67
 
45
68
  The Nuxt MCP server provides guided prompts for common workflows:
46
69
 
47
- - **`find_documentation_for_topic`**: Find the best Nuxt documentation for a specific topic or feature
48
- - **`deployment_guide`**: Get deployment instructions for a specific hosting provider
49
- - **`migration_help`**: Get help with migrating between Nuxt versions
70
+ - **`find-documentation-for-topic`**: Find the best Nuxt documentation for a specific topic or feature
71
+ - **`deployment-guide`**: Get deployment instructions for a specific hosting provider
72
+ - **`migration-help`**: Get help with migrating between Nuxt versions
50
73
 
51
74
  You're able to access these resources with tools like Claude Code by using `/`.
52
75
 
@@ -85,7 +108,7 @@ The Nuxt connector will appear in the composer's "Developer mode" tool later dur
85
108
  Add the server using the CLI command:
86
109
 
87
110
  ```bash
88
- claude mcp add --transport http nuxt-remote https://nuxt.com/mcp
111
+ claude mcp add --transport http nuxt https://nuxt.com/mcp
89
112
  ```
90
113
 
91
114
  ### Claude Desktop
@@ -141,13 +164,30 @@ Or manually create/update `.cursor/mcp.json` in your project root:
141
164
  }
142
165
  ```
143
166
 
167
+ ### Gemini CLI
168
+
169
+ 1. Locate your Gemini CLI configuration file (usually `~/.gemini/settings.json` or as specified in your environment).
170
+ 2. Add the following configuration to your `mcpServers` object:
171
+
172
+ ```json [~/.gemini/settings.json]
173
+ {
174
+ "mcpServers": {
175
+ "nuxt": {
176
+ "httpUrl": "https://nuxt.com/mcp"
177
+ }
178
+ }
179
+ }
180
+ ```
181
+
182
+ 1. Restart your terminal session or reload the CLI. The Nuxt MCP server tools will now be available for use.
183
+
144
184
  ### Le Chat Mistral
145
185
 
146
186
  1. Navigate to "Intelligence" > "Connectors"
147
187
  2. Click on "Add Connector" button, then select "Custom MCP Connector"
148
188
  3. Create your Custom MCP Connector:
149
- - Connector Name : `Nuxt`
150
- - Connector Server : `https://nuxt.com/mcp`
189
+ - Connector Name: `Nuxt`
190
+ - Server URL: `https://nuxt.com/mcp`
151
191
 
152
192
  ### Visual Studio Code
153
193
 
@@ -207,6 +247,55 @@ To verify the MCP server is configured correctly:
207
247
 
208
248
  For more information on using MCP with GitHub Copilot coding agent, see [Extend coding agent with MCP](https://docs.github.com/en/copilot/how-tos/use-copilot-agents/coding-agent/extend-coding-agent-with-mcp).
209
249
 
250
+ ### GitHub Copilot CLI
251
+
252
+ 1. Start GitHub Copilot CLI in interactive mode.
253
+ 2. Run `/mcp add`.
254
+ 3. Fill in the configuration form with:
255
+ - **Server Name**: `nuxt`
256
+ - **Server Type**: `HTTP`
257
+ - **URL**: `https://nuxt.com/mcp`
258
+ - **HTTP Headers**: leave empty
259
+ - **Tools**: `*`
260
+ 4. Press <kbd>Ctrl</kbd>+<kbd>S</kbd> to save. The MCP server is available immediately without restarting the CLI.
261
+
262
+ Or add the server directly to `~/.copilot/mcp-config.json`:
263
+
264
+ ```json [~/.copilot/mcp-config.json]
265
+ {
266
+ "mcpServers": {
267
+ "nuxt": {
268
+ "type": "http",
269
+ "url": "https://nuxt.com/mcp",
270
+ "tools": ["*"]
271
+ }
272
+ }
273
+ }
274
+ ```
275
+
276
+ Use `/mcp show` to confirm the server is configured and available.
277
+
278
+ For more details, see [Adding MCP servers for GitHub Copilot CLI](https://docs.github.com/en/copilot/how-tos/copilot-cli/customize-copilot/add-mcp-servers).
279
+
280
+ ### Google Antigravity
281
+
282
+ 1. Open the MCP store via the "..." dropdown at the top of the editor's agent panel.
283
+ 2. Click on "Manage MCP Servers"
284
+ 3. Click on "View raw config"
285
+ 4. Modify the `mcp_config.json` with your custom MCP server configuration:
286
+
287
+ ```json [mcp_config.json]
288
+ {
289
+ "mcpServers": {
290
+ "nuxt": {
291
+ "serverUrl": "https://nuxt.com/mcp"
292
+ }
293
+ }
294
+ }
295
+ ```
296
+
297
+ 1. Return to the "Manage MCP Servers" tab and click "Refresh". The Nuxt MCP server should now appear.
298
+
210
299
  ### Windsurf
211
300
 
212
301
  1. Open Windsurf and navigate to "Settings" > "Windsurf Settings" > "Cascade"
@@ -217,8 +306,7 @@ For more information on using MCP with GitHub Copilot coding agent, see [Extend
217
306
  {
218
307
  "mcpServers": {
219
308
  "nuxt": {
220
- "type": "http",
221
- "url": "https://nuxt.com/mcp"
309
+ "serverUrl": "https://nuxt.com/mcp"
222
310
  }
223
311
  }
224
312
  }
@@ -234,10 +322,7 @@ For more information on using MCP with GitHub Copilot coding agent, see [Extend
234
322
  {
235
323
  "context_servers": {
236
324
  "nuxt": {
237
- "source": "custom",
238
- "command": "npx",
239
- "args": ["mcp-remote", "https://nuxt.com/mcp"],
240
- "env": {}
325
+ "url": "https://nuxt.com/mcp"
241
326
  }
242
327
  }
243
328
  }
@@ -6,7 +6,7 @@ description: "Learn how Nuxt modules are structured and how to define them."
6
6
  There are two types of Nuxt modules:
7
7
 
8
8
  - published modules are distributed on npm - you can see a list of some community modules on [the Nuxt website](/modules).
9
- - "local" modules exist within a Nuxt project, either [inlined in Nuxt config](/docs/4.x/api/nuxt-config#modules) or within [the `modules` directory](/docs/4.x/directory-structure/modules).
9
+ - "local" modules exist within a Nuxt project, either [inlined in Nuxt config](/docs/api/nuxt-config#modules) or within [the `modules` directory](/docs/directory-structure/modules).
10
10
 
11
11
  In either case, they work in the same way.
12
12
 
@@ -31,7 +31,7 @@ export default function (inlineOptions, nuxt) {
31
31
  }
32
32
  ```
33
33
 
34
- You can get type hinting for this function using the higher-level `defineNuxtModule` helper provided by [Nuxt Kit](/docs/4.x/guide/going-further/kit).
34
+ You can get type hinting for this function using the higher-level `defineNuxtModule` helper provided by [Nuxt Kit](/docs/guide/going-further/kit).
35
35
 
36
36
  ```ts
37
37
  import { defineNuxtModule } from '@nuxt/kit'
@@ -112,9 +112,9 @@ Modules, like everything in a Nuxt configuration, aren't included in your applic
112
112
  Inside the runtime directory, you can provide any kind of assets related to the Nuxt app:
113
113
  - Vue components
114
114
  - Composables
115
- - [Nuxt plugins](/docs/4.x/directory-structure/app/plugins)
115
+ - [Nuxt plugins](/docs/directory-structure/app/plugins)
116
116
 
117
- To the [server engine](/docs/4.x/guide/concepts/server-engine), Nitro:
117
+ To the [server engine](/docs/guide/concepts/server-engine), Nitro:
118
118
  - API routes
119
119
  - Middlewares
120
120
  - Nitro plugins
@@ -128,7 +128,7 @@ Or any other kind of asset you want to inject in users' Nuxt applications:
128
128
  You'll then be able to inject all those assets inside the application from your [module definition](#define-your-module).
129
129
 
130
130
  ::tip
131
- Learn more about asset injection in [the recipes section](/docs/4.x/guide/modules/recipes-basics).
131
+ Learn more about asset injection in [the recipes section](/docs/guide/modules/recipes-basics).
132
132
  ::
133
133
 
134
134
  ::warning
@@ -29,7 +29,7 @@ Watch Vue School video about altering Nuxt configuration.
29
29
 
30
30
  ## Expose Options to Runtime
31
31
 
32
- Because modules aren't part of the application runtime, their options aren't either. However, in many cases, you might need access to some of these module options within your runtime code. We recommend exposing the needed config using Nuxt's [`runtimeConfig`](/docs/4.x/api/nuxt-config#runtimeconfig).
32
+ Because modules aren't part of the application runtime, their options aren't either. However, in many cases, you might need access to some of these module options within your runtime code. We recommend exposing the needed config using Nuxt's [`runtimeConfig`](/docs/api/nuxt-config#runtimeconfig).
33
33
 
34
34
  <!-- TODO: Update after #18466 (or equivalent) -->
35
35
 
@@ -60,7 +60,7 @@ const options = useRuntimeConfig().public.myModule
60
60
  Be careful not to expose any sensitive module configuration on the public runtime config, such as private API keys, as they will end up in the public bundle.
61
61
  ::
62
62
 
63
- :read-more{to="/docs/4.x/guide/going-further/runtime-config"}
63
+ :read-more{to="/docs/guide/going-further/runtime-config"}
64
64
 
65
65
  ::tip{icon="i-lucide-video" to="https://vueschool.io/lessons/passing-and-exposing-module-options?friend=nuxt" target="_blank"}
66
66
  Watch Vue School video about passing and exposing Nuxt module options.
@@ -83,7 +83,7 @@ export default defineNuxtModule({
83
83
  })
84
84
  ```
85
85
 
86
- :read-more{to="/docs/4.x/guide/going-further/kit"}
86
+ :read-more{to="/docs/guide/going-further/kit"}
87
87
 
88
88
  ## Add Components
89
89
 
@@ -132,7 +132,7 @@ export default defineNuxtModule({
132
132
  ::tip{icon="i-lucide-lightbulb"}
133
133
  It is highly recommended to prefix your exports to avoid conflicts with user code or other modules.
134
134
 
135
- :read-more{to="/docs/4.x/guide/modules/best-practices#prefix-your-exports"}
135
+ :read-more{to="/docs/guide/modules/best-practices#prefix-your-exports"}
136
136
  ::
137
137
 
138
138
  ::note
@@ -193,7 +193,7 @@ export default defineNuxtModule({
193
193
  ::tip{icon="i-lucide-lightbulb"}
194
194
  It is highly recommended to prefix your exports to avoid conflicts with user code or other modules.
195
195
 
196
- :read-more{to="/docs/4.x/guide/modules/best-practices#prefix-your-exports"}
196
+ :read-more{to="/docs/guide/modules/best-practices#prefix-your-exports"}
197
197
  ::
198
198
 
199
199
  ::note
@@ -352,7 +352,7 @@ export default defineNuxtModule({
352
352
  ::tip{icon="i-lucide-lightbulb"}
353
353
  It is highly recommended to prefix your server routes to avoid conflicts with user-defined routes. Common paths like `/api/auth`, `/api/login`, or `/api/user` may already be used by the application.
354
354
 
355
- :read-more{to="/docs/4.x/guide/modules/best-practices#prefix-your-exports"}
355
+ :read-more{to="/docs/guide/modules/best-practices#prefix-your-exports"}
356
356
  ::
357
357
 
358
358
  ## Add Other Assets
@@ -371,7 +371,7 @@ export default defineNuxtModule({
371
371
  })
372
372
  ```
373
373
 
374
- And a more advanced one, exposing a folder of assets through [Nitro](/docs/4.x/guide/concepts/server-engine)'s `publicAssets` option:
374
+ And a more advanced one, exposing a folder of assets through [Nitro](/docs/guide/concepts/server-engine)'s `publicAssets` option:
375
375
 
376
376
  ```js
377
377
  import { createResolver, defineNuxtModule } from '@nuxt/kit'
@@ -408,4 +408,4 @@ export default defineNuxtModule({
408
408
  })
409
409
  ```
410
410
 
411
- :read-more{to="/docs/4.x/guide/modules/module-dependencies"}
411
+ :read-more{to="/docs/guide/modules/module-dependencies"}
@@ -54,7 +54,7 @@ The key of each entry identifies the module to depend on. You can use an npm pac
54
54
 
55
55
  ## Depending on Local Modules
56
56
 
57
- When the dependency lives inside the [`modules/` directory](/docs/4.x/guide/directory-structure/modules), use a file path to declare the dependency:
57
+ When the dependency lives inside the [`modules/` directory](/docs/guide/directory-structure/modules), use a file path to declare the dependency:
58
58
 
59
59
  ```ts
60
60
  import { defineNuxtModule } from '@nuxt/kit'
@@ -7,7 +7,7 @@ Here are some advanced patterns for authoring modules, including hooks, template
7
7
 
8
8
  ## Use Lifecycle Hooks
9
9
 
10
- [Lifecycle hooks](/docs/4.x/guide/going-further/hooks) allow you to expand almost every aspect of Nuxt. Modules can hook to them programmatically or through the `hooks` map in their definition.
10
+ [Lifecycle hooks](/docs/guide/going-further/hooks) allow you to expand almost every aspect of Nuxt. Modules can hook to them programmatically or through the `hooks` map in their definition.
11
11
 
12
12
  ```js
13
13
  import { addPlugin, createResolver, defineNuxtModule } from '@nuxt/kit'
@@ -28,7 +28,7 @@ export default defineNuxtModule({
28
28
  })
29
29
  ```
30
30
 
31
- :read-more{to="/docs/4.x/api/advanced/hooks"}
31
+ :read-more{to="/docs/api/advanced/hooks"}
32
32
 
33
33
  ::tip{icon="i-lucide-video" to="https://vueschool.io/lessons/nuxt-lifecycle-hooks?friend=nuxt" target="_blank"}
34
34
  Watch Vue School video about using Nuxt lifecycle hooks in modules.
@@ -184,10 +184,8 @@ nuxt.options.typescript.nodeTsConfig.include ??= []
184
184
  nuxt.options.typescript.nodeTsConfig.include.push(resolve('./augments.d.ts'))
185
185
 
186
186
  // extend tsconfig.server.json
187
- nuxt.options.nitro.typescript ??= {}
188
- nuxt.options.nitro.typescript.tsConfig ??= {}
189
- nuxt.options.nitro.typescript.tsConfig.include ??= []
190
- nuxt.options.nitro.typescript.tsConfig.include.push(resolve('./augments.d.ts'))
187
+ nuxt.options.typescript.serverTsConfig.include ??= []
188
+ nuxt.options.typescript.serverTsConfig.include.push(resolve('./augments.d.ts'))
191
189
  ```
192
190
 
193
191
  Alternatively, you can use the `prepare:types` and `nitro:prepare:types` hooks to extend the TypeScript references for specific type contexts, or modify the TypeScript configuration similar to the example above.
@@ -236,8 +234,8 @@ Nuxt automatically includes your module's directories in the appropriate type co
236
234
 
237
235
  Server routes are also type-checked using `tsconfig.app.json` in addition to `tsconfig.server.json`.
238
236
 
239
- This is required because Nuxt infers the return types of your server endpoints to provide response types in [`$fetch`](/docs/4.x/api/utils/dollarfetch) and [`useFetch`](/docs/4.x/api/composables/use-fetch).
237
+ This is required because Nuxt infers the return types of your server endpoints to provide response types in [`$fetch`](/docs/api/utils/dollarfetch) and [`useFetch`](/docs/api/composables/use-fetch).
240
238
 
241
239
  ::warning
242
- This can cause issues when using **server-only types** in your route files. For example, if a module creates a server-only virtual file using [`addServerTemplate`](/docs/4.x/api/kit/templates#addservertemplate) and you declare types for it in `tsconfig.server.json`, those type declarations will only be available in the server context. When the app context type-checks your server routes, it won't recognize these server-only types and will report errors. To resolve this, you unfortunately need to declare such types in the app context as well.
240
+ This can cause issues when using **server-only types** in your route files. For example, if a module creates a server-only virtual file using [`addServerTemplate`](/docs/api/kit/templates#addservertemplate) and you declare types for it in `tsconfig.server.json`, those type declarations will only be available in the server context. When the app context type-checks your server routes, it won't recognize these server-only types and will report errors. To resolve this, you unfortunately need to declare such types in the app context as well.
243
241
  ::
@@ -15,7 +15,7 @@ We're still discussing and exploring how to ease unit and integration testing on
15
15
 
16
16
  ## Write E2E Tests
17
17
 
18
- [Nuxt Test Utils](/docs/4.x/getting-started/testing) is the go-to library to help you test your module in an end-to-end way. Here's the workflow to adopt with it:
18
+ [Nuxt Test Utils](/docs/getting-started/testing) is the go-to library to help you test your module in an end-to-end way. Here's the workflow to adopt with it:
19
19
 
20
20
  1. Create a Nuxt application to be used as a "fixture" inside `test/fixtures/*`
21
21
  2. Setup Nuxt with this fixture inside your test file
@@ -69,7 +69,7 @@ An example of such a workflow is available on [the module starter](https://githu
69
69
 
70
70
  ## Test Manually
71
71
 
72
- Having a playground Nuxt application to test your module when developing it is really useful. [The module starter integrates one for that purpose](/docs/4.x/guide/modules/getting-started#develop-your-module).
72
+ Having a playground Nuxt application to test your module when developing it is really useful. [The module starter integrates one for that purpose](/docs/guide/modules/getting-started#develop-your-module).
73
73
 
74
74
  You can test your module with other Nuxt applications (applications that are not part of your module repository) locally. To do so, you can use [`npm pack`](https://docs.npmjs.com/cli/commands/npm-pack/) command, or your package manager equivalent, to create a tarball from your module. Then in your test project, you can add your module to `package.json` packages as: `"my-module": "file:/path/to/tarball.tgz"`.
75
75
 
@@ -65,7 +65,7 @@ export default defineNuxtModule({
65
65
  })
66
66
  ```
67
67
 
68
- This pattern prevents unnecessary work on every build and provides a better developer experience. See the [lifecycle hooks documentation](/docs/4.x/api/kit/modules#using-lifecycle-hooks-for-module-installation-and-upgrade) for more details.
68
+ This pattern prevents unnecessary work on every build and provides a better developer experience. See the [lifecycle hooks documentation](/docs/api/kit/modules#using-lifecycle-hooks-for-module-installation-and-upgrade) for more details.
69
69
 
70
70
  ## Be TypeScript Friendly
71
71
 
@@ -75,7 +75,7 @@ Exposing types and using TypeScript to develop modules benefits users even when
75
75
 
76
76
  ## Use ESM Syntax
77
77
 
78
- Nuxt relies on native ESM. Please read [Native ES Modules](/docs/4.x/guide/concepts/esm) for more information.
78
+ Nuxt relies on native ESM. Please read [Native ES Modules](/docs/guide/concepts/esm) for more information.
79
79
 
80
80
  ## Document Your Module
81
81