shelcia / Socialgram

Social Gram is a social media website that allows users to create and share content, similar to other popular platforms such as Twitter and Facebook. Users will be able to create posts, and share them with others. The platform also allows for users to react and engage with other user's content, such as by liking, commenting, or sharing.
https://social--gram.vercel.app/
Apache License 2.0
38 stars 44 forks source link

Add validation on Login and Signup Pages #231

Closed AkashSharma001 closed 1 year ago

AkashSharma001 commented 1 year ago

I've implemented validation using the HTML attribute. To work with HTML validation, I added the onSubmit attribute with the onSubmit Function in the form tag and removed the onClick attribute from the button. Still, in the email, the HTML validation pattern attribute isn't working correctly.

To fix that I have useEffect to check and validate email using a pattern.