Skip to content

Browser redirect to sign up instead of log in? #134

Answered by frankie567
padraigpearlman asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @pap024 👋 Great question! It's actually possible but was poorly documented and tooled. This is now fixed!

So here is how you can do that:

  • We support an optional parameter screen on the authorize URL to force either the login or register page. See here ➡️ https://docs.fief.dev/going-further/authorize-url/
  • The redirectToLogin method of the browser integration was not able to accept those optional parameters. This is now fixed in v0.12.0. Example:
fiefAuth.redirectToLogin('http://localhost:8080/callback.html', { extrasParams: { screen: 'register' } });

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@padraigpearlman
Comment options

Answer selected by padraigpearlman
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants