vue3+ts中 .vue文件引入报错:找不到模块或其相应的类型声明
新创建的vue3项目在vscode打开出现报错:找不到模块或其相应的类型声明
解决:在env.d.ts文件添加配置:
declare module '*.vue' {
import type { DefineComponent } from 'vue'
// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/ban-types
const component: DefineComponent<{}, {}, any>
export default component
}