Submitted about 4 years ago
HTML, CSS, responsive design, some grids and more...
@XavierGM23
Design comparison
SolutionDesign
Solution retrospective
Give me your feedback and some advices, thanks :) Question: is there any other way to center a div without the use of margin, i had trouble on that, but i managed to solve it.
Community feedback
- @ApplePieGiraffePosted about 4 years ago
Hey, Xavier Guzman!
You did a nice job! 👏
Besides using
auto
margins, you can set thedisplay
property of an element's parent container toflex
and then usealign-items: center
andjustify-content: center
to vertically and horizontally center that element within its container, respectively.Keep coding (and happy coding, too)! 😁
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