Register
This is a walk through of registering a user
Overview:
Prerequisites:
Install LoopbackCreate a MongoDBConnect Loopback to MongoDBSetup Token AuthenticationCreate User ModelsOpen your front end angular application in a code editor
Create A Register Component
Create A User Service
References
Intro to ServicesImportant Checks:
Import User Service & Router Inside Register Component
Initialize User Service & Router Inside Register Component Constructor
Collect User Input & Store It In The Register Component
Reminder we have done this before check the following website for help:
Login Page ChallengeImport HttpClient In user.service.ts
HttpClient In user.service.tsInitialize HttpClient Inside user.service.ts Constructor
HttpClient Inside user.service.ts ConstructorIn The User.service.ts File Create The following Attributes in the UserService Class
User.service.ts File Create The following Attributes in the UserService ClassCreate A registerUser Function In The User.service.ts File
registerUser Function In The User.service.ts FileAlter the signUp function inside register.component.ts
signUp function inside register.component.tsTry Creating A New User
Important Notes:
StackBlitz Example
Last updated