DEV Community

Cover image for How To Build Authentication in Angular Using Node and Passport

How To Build Authentication in Angular Using Node and Passport

Jay on November 19, 2019

In this tutorial, you'll learn how to build an authentication in your Node Angular app using Passport.js. The tutorial assumes the reader to be fa...
Collapse
 
abhaystacks profile image
Abhay

ERROR in src/app/app-routing.module.ts(7,59): error TS2304: Cannot find name 'AuthGuard'.

Collapse
 
jay3dec profile image
Jay Jscrambler

Hello, it seems you missed to import the AuthGuard and I missed to reference that in the tutorial also. My bad :)
Simply do,

import { 
  AuthGuardService as AuthGuard 
} from './auth-guard.service';

in app-routing.module.ts. And you should be good to go. Please refer the source code attached in the tutorial for further reference. Thanks for reading.