Created
April 25, 2016 06:38
-
-
Save jbrz0/a6f0f6a1d94a584ee8797c145ff3679c to your computer and use it in GitHub Desktop.
Sass mixin for quickly applying clearfix
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
// Clearfix mixin | |
%clearfix { | |
*zoom: 1; | |
&:before, &:after { | |
content: " "; | |
display: table; | |
} | |
&:after { | |
clear: both; | |
} | |
} | |
// Usage | |
.container-with-floated-children { | |
@extend %clearfix; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment