DEV Community

MoonLight
MoonLight

Posted on

box sizing Css Mosh

content box

div {
box-sizing: content-box;
width: 100%;
border: solid #5B6DCD 10px;
padding: 5px;
}
Enter fullscreen mode Exit fullscreen mode

Image description

border box

div {
box-sizing: border-box;
width: 100%;
border: solid #5B6DCD 10px;
padding: 5px;
}
Enter fullscreen mode Exit fullscreen mode

Image description

we should use these codes for ::before ::after
Image description

Top comments (0)