Responsive card with HTML and CSS using GRID and FLEX

Solution retrospective
I needed to replace an image based on the window width, so I used a picture
element to include both versions and controlled which one was displayed using a media query, as follows:
<picture>
<source srcset="images/image1.jpg" media="(min-width: 801px)">
<img src="images/image2.jpg" alt="Responsive image">
</picture>
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on Daniel's solution.
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