Skip to content

WaysToGo/CSS-tips

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 

Repository files navigation

CSS-tips

Using ems can be convenient when setting properties like padding, height, width, or border-radius

use rems for font sizes, pixels for borders, and ems for most other measures, especially paddings, margins, and border radius

*,
::before,
::after {
box-sizing: border-box;
}

More robust universal border-box fix third-party components with their own CSS might break if they are not using border-box

:root {
box-sizing: border-box;
}
*,
::before,
::after {

box-sizing: inherit;
}

.third-party-component {
box-sizing: content-box;
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published