Created
October 14, 2011 10:44
-
-
Save jakearchibald/1286795 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
<div class="whatever"> | |
<style> | |
.whatever { | |
p { | |
margin: 0; | |
} | |
} | |
/* Or even better... */ | |
:root { | |
p { | |
margin: 0; | |
} | |
} | |
/* Where :root would be the style root element, rather than document root element */ | |
</style> | |
<link rel="stylesheet" href="..."> | |
<div>...More stuff...</div> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
cool. Since the
:root
method achieves effectively the same thing asscoped
, I'd be very happy to put my vote on it (or something similar that's back-compat). thx for gisting this! -- J