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 javascript for responsive images

Mishael 60

@mishael-codehq

Desktop design screenshot for the News homepage coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
2junior
View challenge

Design comparison


SolutionDesign

Solution retrospective


the main problem I had was switching the blog post image according to the screen sizes because the "srcset" HTML attribute didn't work on my machine.

Community feedback

@victoribironke

Posted

Hi, your work is clean, good job. For changing the blog post image, you can try using the background image property. background-image: url('path-to-the-image');, or have two separate divs for the two screen sizes, then set a display: none; to the one you don't need in the media query. I like the second one better. The header's list items shouldn't spread out as the page's width increases, the "New" section could use a bit of work and I saw some typos but overall, good job.

Marked as helpful

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