Design comparison
Solution retrospective
I'm proud of creating a stylish and responsive product preview page using HTML, CSS, and Bootstrap, particularly integrating images for different screen sizes and maintaining a consistent design with CSS variables. Next time, I would add subtle animations or interactions, review the CSS organization for better modularity, and focus more on testing the site's accessibility.
Community feedback
- @mkborisPosted 3 months ago
Great work @deusdeteneto, here are a few things to review
- To handle responsive images effectively you can use the
picture
element. This allows you to specify different images for various screen sizes and resolutions. Using CSS to hide and show images to display differently on various screen sizes is not part of the best practices. - It's best practice linking Google fonts directly in the HTML
head
section rather than directly in your CSS file as it enables asynchronous downloading, improving page load times. - Media queries should be defined in
rem
not px - Consider using a modern CSS reset at the start of the styles in every project. Like this one Modern CSS Reset. This will help reset a list of default browser styles.
- Font-size should be written in
rem
not px. This article explains it better Why font-size must NEVER be in pixels. - Use a class instead of an ID for styling to keep specificity low, reserve IDs for JavaScript manipulation.
Marked as helpful1@deusdetenetoPosted 3 months agoThank you very much @mkboris for the feedback! I really wasn’t aware of all these practices. I read the articles you mentioned and found them very enlightening. I will review this entire structure at some point or redo it with a fresh perspective and more experience.
1 - To handle responsive images effectively you can use the
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