@Hassiai
Posted
To center .child on the page using flexbox, add min-height:100vh; display: flex; align-items: center: justify-content: center; to the body
body{
min-height: 100vh;
display: flex;
align-items: center;
justify-content: center;
}
there is no need to give ,.child position: absolute and its properties and a margin value.
Use relative units like rem or em as unit for the padding, margin, width values and preferably rem for the font-size values, instead of using px which is an absolute unit. For more on CSS units Click here and here
Hope am helpful.
Well done for completing this challenge. HAPPY CODING
Marked as helpful
@Gwen-lego
Posted
Hi @Hassiai,
Thank you for the feedback, the link you provided are really helpful. I do understand the importance of units, now 😄.
Have a good one. Cheers Gwen