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

News-homepage using HTML Css and JavaScript

@OketchOdanga

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


I found adding the images for the desktop and mobile challenging . Any help on how it can done smoothly

Community feedback

@AlfredoPegueroC

Posted

Hello, @OketchOdanga

There is a tag that offers alternative versions of the same image for different displays. It's called the 'picture' tag.

Here is the example Picture tag in mdn.

I hope it helps

Marked as helpful

1

@OketchOdanga

Posted

@AlfredoPegueroC Thanks for your feedback. I have read the article and will try to implement it in my future projects.

I have a question. Is it better to user background property in css for the image if the desktop and mobile layout are different? As in this case?

0

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