Created
September 20, 2016 09:42
-
-
Save geraldyeo/f80fb3b52d0aa8897b3a6fef64d384bc to your computer and use it in GitHub Desktop.
Inheriting box-sizing as best practice
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
/* | |
* This will give you the same result, and make | |
* it easier to change the box-sizing in plugins | |
* or other components that leverage other behavior. | |
* @see https://css-tricks.com/inheriting-box-sizing-probably-slightly-better-best-practice/ | |
*/ | |
html { | |
box-sizing: border-box; | |
} | |
*, *:before, *:after { | |
box-sizing: inherit; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment