Newsletter Sign Up Form Vanilla CSS HTML JavaScript
Design comparison
Solution retrospective
I was not sure how to complete the full email validation so I did what I could. If anyone has some tips for me that would be greatly appreciated.
Community feedback
- @mahmoud-w-elgendyPosted over 1 year ago
Hi Lisa👋, I think I have some suggestions that might help :)
-
Maybe the best way to validate a form is by using Regular expressions, and using
match()
method which returns true if the email entered by the user is valid, it will be a good idea to use it with an if statement. -
input.value
will give us user's input, we can store it in a variable to validate or use it anywhere else. -
The
<picture>
element in HTML will be very useful when you need responsive images that appears in specific screen size, I strongly recommend that you read this article Responsive Images.
Great Job, and happy coding ! ☕
0@CrypticMangoPosted over 1 year agoThank you for the tips! I will go over it and make some changes. @mahmoud-w-elgendy
1 -
Please log in to post a comment
Log in with GitHubJoin 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