Hovering button doesn’t show URL preview – Gatsby

I have just started using Gatsby, by using the code below, it won't display the destination URL at the bottom left of the browser when hovering the button. The only way is to wrap the button into a <Link> which is not the best choice from an HTML perspective. May you point me to the right direction? Thank you.

import { navigate } from "gatsby"

<button onClick={()=>{navigate("/contact/")}} role="link">Contact Now</button>


Read more here: https://stackoverflow.com/questions/66340483/hovering-button-doesnt-show-url-preview-gatsby

Content Attribution

This content was originally published by Simone Mas at Recent Questions - Stack Overflow, and is syndicated here via their RSS feed. You can read the original post over there.

%d bloggers like this: