Created
March 8, 2021 11:14
-
-
Save hereischen/7a8e2e6ee638f734117f0b4b780a2a86 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:root { | |
box-sizing: border-box; // 1 | |
} | |
*, | |
::before, | |
::after { | |
box-sizing: inherit; // 2 | |
} | |
// 1 Applies border box sizing to the root element | |
// 2 Tells all other elements and pseudo-elements to inherit their box sizing |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment