Design comparison
SolutionDesign
Solution retrospective
Any and all feedback are welcomed.
Community feedback
- @prantiknoorPosted over 2 years ago
Hey @leoikeh99. I have a little recommendation.
You used two
img
(one for mobile & another for desktop). You switched between images usingdisplay
property.But there is a better alternative solution. You can use
picture
. as an example:<picture class="image"> <source media="(max-width: 630px)" srcset="./images/image-product-mobile.jpg"> <img src="./images/image-product-desktop.jpg" alt="product image" class="desktop" /> </picture>
Marked as helpful0@leoikeh99Posted over 2 years ago@prantiknoor Thank you very much for this, i'll use this
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