How to redirect to a different page based on signup vs login screen?

Hi @victor-wei126,

I just tested this out without doing step 1, and the redirect still occurs. I was mistaken, that step is not necessary for this.

You can simply update the app state when you call loginWithRedirect:

                  <Button
                    id="qsLoginBtn"
                    color="primary"
                    className="btn-margin"
                    onClick={() => loginWithRedirect({
                      screen_hint: 'signup',
                      appState: {
                        returnTo: '/signupinfo'
                      }
                    })}
                  >
                    Sign up
                  </Button>

The appState is used to store the application’s state before the user is redirected: https://auth0.github.io/auth0-react/modules/auth0_provider.html#appstate

The onRedirectCallback method can be used if you are using a custom router such as react-router-dom: https://auth0.github.io/auth0-react/interfaces/auth0_provider.auth0provideroptions.html#onredirectcallback