Supabase forces page redirect after oAuth login?
I'm currently trying to set up oAuth in our Vue 3 app running on vite, but I'm having some difficulty redirecting users back to where they were trying to access before they logged in.
The flow I'm currently trying is:
Does supabase force this redirect? And is there a way to disable this?
The flow I'm currently trying is:
- User accesses protected url and is redirected to login page with redirectTo query param set to the url they tried to access
- User chooses oAuth provider and clicks the provider they want
- i set the redirect in localStorage and call the signin with the provider and the redirectTo option set to our callback page
- user is logged in and redirected to our callback page
- before the callback page we validate the url fragments are set, get the redirect from localstorage and redirect to the url
- user is now logged in and on the correct page
Does supabase force this redirect? And is there a way to disable this?