vercel/speed-insights

Astro import using wrong types

nblackburn opened this issue · 1 comments

I have been having issues integrating this library for a while now due to some issues in how types are being resolved, which doesn't play nicely with astro check. It looks like some attempts have been made to fix this, but sadly this issue still persists for me.

src/layouts/base.astro:89:10 - error ts(2604): Component 'SpeedInsights' is not a valid component.

If this is a Svelte or Vue component, it might have a syntax error that makes it impossible to parse.

89         <SpeedInsights />
            ~~~~~~~~~~~~~

I have noticed that the Astro version is missing from typesVersions and doesn't have a index.d.ts file, which appears to lead it to default back on index.d.ts under ./dist which is not an Astro component.

Related: #36 #54