Design comparison
Solution retrospective
When should we use Padding and When Should we use margin, as I think using margin just breaks the flow
Community feedback
- @perezjprz19Posted almost 3 years ago
👋Hi!
[This article might helpful in choosing when to use padding vs margin]
(https://medium.com/frontendshortcut/margin-vs-padding-c1fc8ea8bfaf)
Marked as helpful1@Rex-ArnabPosted almost 3 years ago@perezjprz19 thanks it answers my questions in a way at least
1@perezjprz19Posted almost 3 years ago@Rex-Arnab you're welcome! I usually start with one and tweak stuff until it works lol 😆 it helped me to look at the box model in the dev tool and from then on, I think of padding as an invisible field that makes my content take up more space where as margin is a repelling barrier that keeps other content away.
1
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