solidjs / solid-router

A universal router for Solid inspired by Ember and React Router
MIT License
1.14k stars 147 forks source link

TypeScript checker error: Interface 'AnchorProps' incorrectly extends interface 'Omit<AnchorHTMLAttributes<HTMLAnchorElement>, "state">' #302

Closed huseeiin closed 8 months ago

huseeiin commented 1 year ago

Describe the bug

node_modules/@solidjs/router/dist/components.d.ts:47:18 - error TS2430: Interface 'AnchorProps' incorrectly extends interface 'Omit<AnchorHTMLAttributes<HTMLAnchorElement>, "state">'.
  Types of property 'replace' are incompatible.
    Type 'boolean | undefined' is not assignable to type 'boolean'.
      Type 'undefined' is not assignable to type 'boolean'.

47 export interface AnchorProps extends Omit<JSX.AnchorHTMLAttributes<HTMLAnchorElement>, "state"> {
                    ~~~~~~~~~~~

Found 1 error in node_modules/@solidjs/router/dist/components.d.ts:47

Your Example Website or App

https://github.com/xxxhussein/solidjs-reprod

Steps to Reproduce the Bug or Issue

install @solidjs/router run tsc without skipLibCheck: true

Expected behavior

for the error to not occur

Screenshots or Videos

No response

Platform

Additional context

No response

femincan commented 10 months ago

I've tried but couldn't reproduce the issue. Everything seems working normally.

ryansolid commented 8 months ago

reproduction seems to be gone now as well. Closing.