Skip to content

How to handle Auth with WebBrowser.openAuthSessionAsync? #20981

Discussion options

You must be logged in to vote

Helped me through, despite not being the same problem the use the URL quote helped me solve this by changing a bit how I thought about it!

The final result became a little too big to paste here, but the handling ended up being relatively straightforward:

  useEffect(() => {
    if (result?.type === "success") {
      const { token, iv } = getParamsFromUrl(result.url)

      const session = decrypt(token, key, iv)
      console.log({ session })
    }
  }, [result])

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by rafaelrcamargo
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants