Design comparison
Community feedback
- @GMarqzPosted 25 days ago
Hi there! 👋 Good job on completing the challenge!
I noticed you’re using
px
units, which can work, butrem
might be a great option for improved responsiveness! Usingrem
scales more consistently across different devices and screen sizes. What do you think about experimenting with it here? If that interests you, you can read about it here.You might also consider using the
box-sizing: border-box;
.Border-box tells the browser to account for any border and padding in the values you specify for an element's width and height. If you set an element's width to 100 pixels, that 100 pixels will include any border or padding you added, and the content box will shrink to absorb that extra width. This typically makes it much easier to size elements. - developer.mozila
To set up both a padding/margin reset and
border-box
in one go, you could use the universal selector like this:* { margin: 0; padding: 0; box-sizing: border-box; }
You can check more about universal selectors here📗 and more about box-sizing here📗.
I hope this is helpful. Keep it up!
Marked as helpful1@FaiqaShafqat79Posted 22 days ago@GMarqz Thank you for taking the time to review my code—I really appreciate it. I now understand how to use rem
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