I am attempting to create a named export in one of my components like so:
export interface ITest { t: String }
in order to use it in another component:
import { ITest } from '@/components/Test.vue'
However, I am encountering this error:
TS2614: Module '"*.vue"' has no exported member 'ITest '. Did you mean to use 'import ITest from "*.vue"' instead?
When I change the import statement to:
import ITest from '@/components/Test.vue'
The error message changes to:
Module '"(path)/Test.vue"' has no default export. Did you mean to use 'import { ITest } from "(path)/Test.vue"' instead?
Could someone please provide guidance on how to achieve named exports in Vue using TypeScript?
This project is built with Vue 3, TypeScript, and Webpack 5.