Design comparison
Solution retrospective
im so proud that my javascript skills have improved!! im feeling like a god already!!!!!!.. for sometime now i have had some issues with mobile responsiveness but i continued to do it by now i already know how to get the mobile to be responsive and im super proud of all of this.. this is my best work yet and i am looking forward to so much more.
What challenges did you encounter, and how did you overcome them?had some little stress with java script. yes but over came it. im still looking forward to learning diverse ways of implementing java script.
What specific areas of your project would you like help with?all feedbacks are welcomed
Community feedback
- @dylan-dot-cPosted 3 months ago
Congratulations on completing this challenge, good job.
In terms of design, you did well, only issue is that you didn't add any padding to the input element and the website isn't responsive for smaller screens as well as the design is a different.
For functionality I like that you actually have a separate page for the success element, most people(including myself) used a framework and state to replace the whole container. But there is one issue on that side, the email you have is static and I believe that it should match whatever email that is entered into the input field. So what I suggest is that you find a way to send the email entered from the first page to the second one, and what better way to do so that htmlQueryParams and what makes it even easier on your side is when you did this:
<form action='success.html' id='form'>
This makes that when you submit your form it will go directly to that page and pass any information entered into your form to the success page through htmlQueryParams, but one small detail you missed out was to actually include a name property in your input field so thats how data is passed and thats why its good to have a name property. So your new code should now be:
<input placeholder="[email protected]" id="email" name="email">
and then you can just use URLQueryParams to get the email property and the use it to replace the default email that you have there.
const queryString = window.location.search const params = new URLSearchParams(queryString) const email = params.get('email')
And ofcourse you can do some extra checks to make sure everything is good like using the .has method to make sure it exists and you can reuse your isEmail function to make sure its actually good and if not show some kind of error message.
All the best.
0
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