Created
June 21, 2022 04:04
-
-
Save goforbg/e72fa18754a2f1456a9f43d87f3f67a9 to your computer and use it in GitHub Desktop.
Get Query Params in Next JS without Next JS Router
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
//https://regex101.com/r/gmICzZ/1 | |
const params = new URLSearchParams(window.location.href.match(/\?.*/)[0]); | |
const callBackUrl = params?.get("callbackUrl") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment