Closed themataleao closed 1 month ago
I am able to trick the typescript compiler with
router.push(link as `/{string}`)
but I assume thats not intended :)
Good catch, that is indeed not intended 🙂 I'll fix that.
The workaround you used should work for the moment. Alternatively you could use the useRouter
exported from next/navigation
when you want external links. This won't translate internal links though
You are right I could use the regular one from next/navigation
. Thanks :)
When I am using the useRouter component and route to an external link it throws me a type error:
Argument of type '"https://google.com"' is not assignable to parameter of type '
/${string}'
Any other suggestion to route to external URLS?