Last active
December 14, 2015 15:39
-
-
Save evandroeisinger/5109264 to your computer and use it in GitHub Desktop.
Clearfix: CSS float’s problem fix.
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
/* Solve CSS float problem */ | |
.clearfix { | |
*zoom: 1; | |
} | |
.clearfix:before, | |
.clearfix:after { | |
clear: both; | |
content: " "; | |
display: block; | |
} |
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
/* SASS Version: Solve CSS float problem */ | |
.clearfix { | |
*zoom: 1; | |
&:before, &:after { | |
clear: both; | |
content: " "; | |
display: block; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment