Closed Dmanoj07 closed 1 month ago
SPRINT TASK: Sprint Tasks:
-Design UI Components:
Implement Client-Side Validation:
Backend Integration:
Database Operations:
Clerk, out auth solution, actually has a Manage Account
feature implemented - no extra code required. With the Google sign in option, users can change their name and profile picture from this modal. We can customize this modal to instead be a web page for a certain route, although the modal does not force the user to change pages. If we would like to change the sign in option to email and password, Clerk will likely also allow the user to change their email and password as well. The UI components are also provided by Clerk.
For the backend, all we need to do is implement a middleware to authorize the request based on the user's session. The reference for this is here, I briefly got started playing with it in the routes dir. On line 30 I create /clerk-test
which uses a middleware Clerk provides, it works well. However, we may want to create a custom one to return a customized error.
To review
ClerkExpressRequireAuth()
middleware function
Description We will develop a profile section using React and Next.js. In this section, users can modify their registered name, email address, and password. We'll divide the profile update process into two parts: Name and Email, and Reset Password. Once they submit their new profile details, we will perform client-side validation. Upon successful validation, we will update their credentials in our database..
Acceptance Criteria
Name and Email Update:
Password Reset:
Testing Criteria
Name and Email Update:
Password Reset: