Design comparison
SolutionDesign
Solution retrospective
Struggling with matching the sizing, feel a lot better about the organization of my css and starting to get better at using less code and not repeating myself. Please let me know if there are any best practices or ways to reduce / refactor my css / html!
Community feedback
- @p-tamPosted 10 months ago
To further reduce css code you can utilise HTML source set attribute to switch images between screen sizes.
<picture> <source media="(min-width:650px)" srcset="img_pink_flowers.jpg"> <source media="(min-width:465px)" srcset="img_white_flower.jpg"> <img src="img_orange_flowers.jpg" alt="Flowers" style="width:auto;"> </picture>
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