Intro-Component-With-Sign-Up-Form using HTML,CSS & vanilla JavaScript

Solution retrospective
How do I remove errors when I start to fill the form after getting errors due to empty input and other feedback also helps a lot :)
Please log in to post a comment
Log in with GitHubCommunity feedback
- @UrbanskiDev
Hello Abhilash !
Congratulation for finishing your project
To remove the errors when the form is filled, you can use the same idea than you used for showing the errors !
The code you use to show an error :
document.querySelector(".def").classList.remove("error");
To remove an error, you just have to add the class again !
document.querySelector(".def").classList.add("error");
I hope it helps you, keep learning and happy coding !
- @dazzlerabhi30800
you can use onchange property on each input
Join our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord