#External Svelte component type error

2 messages · Page 1 of 1 (latest)

spark vector
#

Hi! Whenever i import a svelte component from an external package, i end up getting type errors for the props.

Type '{}' is not assignable to type 'IntrinsicAttributes & ComponentConstructorOptions<{ name?: string | undefined; animated?: boolean | undefined; }>'.

Even if i pass all props (which are optional), i still get a type error.

Type '{ name: string; animated: boolean; }' is not assignable to type 'IntrinsicAttributes & ComponentConstructorOptions<{ name?: string | undefined; animated?: boolean | undefined; }>'.

This does not happen on SvelteKit projects.