Closed recallwei closed 1 year ago
Cannot find the astro component.
Maybe it should generate a .d.ts file automatically?
I actually explored type generation previously — work is in this branch: https://github.com/delucis/astro-auto-import/tree/type-generation
In general I’m not convinced auto-importing is a best practice inside .astro
files, so that was a big reason I decided against including type generation in the main release. While I think it can be handy in content files (like MDX), I’d advise against using an auto-import in .astro
and to prefer an explicit import
instead.
I’m going to drop support for use of auto imports in .astro
files in the next release — only MDX will be supported. MDX isn’t type checked, so I’ll close this issue.