Directly redirect to login page instead of welcome page with login button

I was following the sample here samples-js-react/okta-hosted-login at master · okta/samples-js-react · GitHub.
In my application I need this to be implemented in another way, that is when user hits the url it should directly take the browser to the okta login page, instead of showing the

welcome, click to login

page.

What changes are needed in the above example to make that work?

P.S: New to this as well as React.

How are you creating your users?

Which URL do you want this to happen on?

That’d be my app url.
Instead of seeing “click to login” page, I want the login page to be redirected to.

So I did this:

{!this.state.authenticated &&
  this.login()
}

and that solves it.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.