Don't worry. I did, too ! That's when I started exploring how to get the functionality of Cognito working in React.
This is a simple project I made to test out the workings of AWS Cognito's JavaScript SDK.
I am not a frontend developer, so I didn't make anything for the designs.
This is just supposed to be a working demo, meant to be used as a reference for the functionality of the project.
It's just a 3 step process (assuming you have AWS Cognito User Pools set up already) :
- Open your IDE (or
cd
into the directory) and create a new.env
file.
2.Inside the file, add two variables (REACT_APP_USER_POOL_ID
& REACT_APP_CLIENT_ID
) using key values from the AWS Cognito dashboard.
- Run
npm install && npm start
and you can begin exploring !
It has 5 components of Cognito : Signup, Login, Session Status, Change Password, Change Email.
(NOTE : The verification should be set to "Link" as I don't have any design/code for OTP verification)