WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Global Component Types

山吹色御守 edited this page Jul 1, 2025 · 3 revisions

After registering your global components you can register them in the GlobalComponents interface.

Type declaration

Add a declaration file, eg. components.d.ts:

declare module 'vue' {
  export interface GlobalComponents {
    Test: typeof import('./src/Test.vue')['default'];
  }
}

export {};

Clone this wiki locally