I am using svelte in combination with Typescript. When importing and using the Route component, I get the following error and suggestion:
Argument of type 'typeof Route' is not assignable to parameter of type 'ConstructorOfATypedSvelteComponent'.
Possible causes:
- You use the instance type of a component where you should use the constructor type
- Type definitions are missing for this Svelte Component. If you are using Svelte 3.31+, use SvelteComponentTyped to add a definition:
import type { SvelteComponentTyped } from "svelte";
class ComponentName extends SvelteComponentTyped<{propertyName: string;}> {}
Is it possible to add this type definition for the route component?
I am using svelte in combination with Typescript. When importing and using the Route component, I get the following error and suggestion:
Is it possible to add this type definition for the route component?