From the course: React: Authentication
Unlock this course with a free trial
Join today to access over 24,900 courses taught by industry experts.
Setting up OAuth on Google - React.js Tutorial
From the course: React: Authentication
Setting up OAuth on Google
- [Instructor] All right, so now that we've learned the basics of how OAuth works, we're going to take a look at an example of how to incorporate OAuth into our application. Now, as I said, there are many different OAuth providers that we could choose from, but we're going to be using Google since it's by far the most popular. So we're going to be adding a login with Google button to the login page for our app. And in order to do this, our first step, as you can see in the screen here, is going to be to set up a project in Google so that Google will allow us to use OAuth for our application, all right? Basically, this is just where we'll tell Google about our project, what data we want to access on our users, stuff like that. So let's start by going to console.cloud.google.com. That should take you to a page that looks like this. You will have to sign in with your Google account in order to get here. So you may need to create an account, just do whatever you need to do there. It's a…
Contents
-
-
-
-
-
-
(Locked)
OAuth basics3m 45s
-
(Locked)
Setting up OAuth on Google7m 39s
-
(Locked)
Adding an OAuth URL route6m 16s
-
(Locked)
Creating a "sign-in with Google" button6m
-
(Locked)
Adding an OAuth callback route4m 17s
-
(Locked)
Loading user info from Google3m 30s
-
(Locked)
Creating new users from OAuth data5m 49s
-
(Locked)
Handling successful OAuth authentication4m 7s
-
(Locked)
-
-
-
-