Skip to content
This repository was archived by the owner on Apr 6, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/nuxt/src/components/templates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ export const componentsTypeTemplate: NuxtTemplate<ComponentsTemplateContext> = {
])

return `// Generated by components discovery
declare module 'vue' {
declare module '@vue/runtime-core' {
export interface GlobalComponents {
${componentTypes.map(([pascalName, type]) => ` '${pascalName}': ${type}`).join('\n')}
${componentTypes.map(([pascalName, type]) => ` 'Lazy${pascalName}': ${type}`).join('\n')}
Expand Down
4 changes: 2 additions & 2 deletions packages/nuxt/src/head/runtime/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import { defineNuxtPlugin, useNuxtApp } from '#app'
import { appHead } from '#build/nuxt.config.mjs'

type MetaComponents = typeof Components
declare module 'vue' {
export interface GlobalComponents extends MetaComponents { }
declare module '@vue/runtime-core' {
export interface GlobalComponents extends MetaComponents {}
}

const metaMixin = {
Expand Down
2 changes: 1 addition & 1 deletion packages/nuxt/src/pages/runtime/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import routerOptions from '#build/router.options'
// @ts-ignore
import { globalMiddleware, namedMiddleware } from '#build/middleware'

declare module 'vue' {
declare module '@vue/runtime-core' {
export interface GlobalComponents {
NuxtPage: typeof NuxtPage
/** @deprecated */
Expand Down