Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

I used Flex box and for Responsiveness i used Media queries.

@Deepu23456

Desktop design screenshot for the Newsletter sign-up form with success message coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
2junior
View challenge

Design comparison


SolutionDesign

Solution retrospective


What are you most proud of, and what would you do differently next time?

I proud on myself for completing this task without anyone's help by myself only. These new tasks teach me a lot and enhance my thinking power of solving the problems. So that is why i proud on myself for being solved those problems.

What challenges did you encounter, and how did you overcome them?

This time it's is not that much challenging but yes there are many tiny things which teaches us a lot more about how to think wisely to solve these kind of problems.

What specific areas of your project would you like help with?

I like help with CSS and basics of Javascript.

Community feedback

@R3ygoski

Posted

Hello Deepu, congratulations on completing your project, it was very well done.

I would like to give a suggestion, you could also use the email pattern in JavaScript, storing it in a variable, which would help keep your HTML cleaner, but this is more a matter of taste, your project as it is, is good.

Now, a tip about CSS, when you are using font size, I strongly recommend using rem, because this unit of measurement is able to adjust to the user's font settings, thus providing more responsiveness and accessibility to your page.

Another tip, now related to HTML, would be to use more semantic tags, your HTML structure is correct, but it lacks semantics. Some examples:

  • <div class="image-container"> instead of using a div, you could use a <figure>, because this is a main image of your page.
  • <div class="container"> instead of using a div, here you could use an <article>, because the content here is self-explanatory.

And another thing I noticed in your HTML, is that you used a <div> to create the form, it is more recommended to use a <form>, as that is a form area, so it is the most correct. Just note that if you use the <form>, in your JavaScript, you have to do something like this:

const form = document.querrySelector('#form')

form.addEventListener('submit', (e)=>{
    e.preventDefault()
})

This way you prevent the form from reloading the page when the button is pressed.

And again, congratulations on your project, it was very well done, and your JavaScript is very good, keep practicing and improving, if you have any doubts, please comment below and I will try to help in the best way possible.

Marked as helpful

0

@Deepu23456

Posted

Hello @R3ygoski sir/ma'am Thanks for your feedback i will keep these things you mentioned above in my mind. Your feedback motivates me to work more on my faults. As this is very helpful for me this comment refresh my mind to think in other ways to keep this code optimized, responsive and accessible as you said. I will surely implement all those things you mentioned and explore more.....

1

Please log in to post a comment

Log in with GitHub
Discord logo

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