From the course: Building Applications with Angular, ASP.NET Core, and Entity Framework Core
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Logging in
From the course: Building Applications with Angular, ASP.NET Core, and Entity Framework Core
Logging in
- [Instructor] In this video, we will modify our front end and back end to support logging in. Let's begin on our front end project. Let's go over to our nav component, and lets add a new button by copying the register button on line nine and pasting it below. We'll rename it to login, and then we'll change the path to login as well. Next, lets create a new file called login.component.ts, and lets go to our register component and copy and paste that as a template. Then let's modify the class name to login component and change the template URL to login component. I'll save that, and then let's create a new file for our HTML. And once again, we'll use the register HTML as a template. Let's change the button from register to login, and then the call on ng submit on line two from auth.register to auth.login. Let's save that and close it out. Then let's go to our auth service and we'll add a login function by copying the register function and pasting it below. I'll rename it to login, and…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
-
-
-
(Locked)
Set up Identity Framework13m 31s
-
(Locked)
Register from Angular4m 26s
-
(Locked)
Reactive forms with FormBuilder5m 49s
-
(Locked)
Save token in the browser3m 39s
-
(Locked)
Pass token with Angular requests5m 6s
-
(Locked)
Auth token middleware in ASP.NET7m 55s
-
(Locked)
Associate user with quiz and question5m 35s
-
(Locked)
Logging in6m 38s
-
(Locked)
Logging out3m 23s
-
(Locked)
-
-