nodegui / svelte-nodegui-starter

55 stars 7 forks source link

ERROR in src/app.ts:4:15 TS2345: Argument of type 'typeof SvelteComponentDev' is not assignable to parameter of type 'typeof SvelteComponent'. Types of construct signatures are incompatible. #9

Open shenghan97 opened 2 years ago

shenghan97 commented 2 years ago

Hey!

I just cloned this repository and installed dependencies but when I tried to run npm run dev. I got this error message:

ERROR in src/app.ts:4:15
TS2345: Argument of type 'typeof SvelteComponentDev' is not assignable to parameter of type 'typeof SvelteComponent'.
  Types of construct signatures are incompatible.
    Type 'new (options: IComponentOptions<Record<string, any>>) => SvelteComponentDev' is not assignable to type 'new (options: { target?: NSVElement<NativeView<Component>> | Element; props?: any; anchor?: NSVElement<NativeView<Component>> | Element; intro?: boolean; }) => SvelteComponent'.
      Types of parameters 'options' and 'options' are incompatible.
        Type '{ target?: NSVElement<NativeView<Component>> | Element; props?: any; anchor?: NSVElement<NativeView<Component>> | Element; intro?: boolean; }' is not assignable to type 'IComponentOptions<Record<string, any>>'.
          Types of property 'target' are incompatible.
            Type 'NSVElement<NativeView<Component>> | Element' is not assignable to type 'Element | ShadowRoot'.
              Type 'NSVElement<NativeView<Component>>' is not assignable to type 'Element | ShadowRoot'.
                Type 'NSVElement<NativeView<Component>>' is missing the following properties from type 'Element': attributes, classList, className, clientHeight, and 139 more.

Hope there's a fix for that! Thanks

eikaramba commented 2 years ago

see https://githubmemory.com/repo/nodegui/svelte-nodegui-starter/issues/7

alber70g commented 1 year ago

Any resolution on this?