Last active
July 17, 2022 15:51
-
-
Save DoctorDerek/3ab226a084294de109a8d62ae4b70d5d to your computer and use it in GitHub Desktop.
How To Redirect to Another Webpage Using JavaScript To Change the URL https://medium.com/p/2b92754845a3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<button | |
onClick={() => { | |
window.location.href = 'https://google.com' | |
}} | |
> | |
</button> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment