Replies: 1 comment
-
Hey, is your routes in your code are typed like this? type RouteType = {
href : "url" | "anotherUrl"
} In that case you'll need cast the type to avoid that typescript warning. You can try something like this: <Link href={"yourUrl" as "youtTypeUrl"} /> Lmk if it worked. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have tanstack router
And them i use Link component, href is strongly typified with my routes
<Link href="tasks/$taskId" />
how to pass taskId into Link?
i used string literal, but TS yeels at cause of 'string is not assignable ...'
Beta Was this translation helpful? Give feedback.
All reactions