Created
January 30, 2021 05:36
-
-
Save secretpray/dad52bcc2e52cc40e6b371d215f6ac15 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| var fragmentQueryParameters = {}; | |
| window.location.hash.slice(1).replace( | |
| new RegExp("([^?=&]+)(=([^&]*))?", "g"), | |
| function($0, $1, $2, $3) { fragmentQueryParameters[$1] = $3; } | |
| ); | |
| // Access fragment query parameters in fragmentQueryParameters object, e.g. fragmentQueryParameters.access_token |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment