Skip to content

Instantly share code, notes, and snippets.

@ddnode
Created March 29, 2013 07:14
Show Gist options
  • Save ddnode/5269252 to your computer and use it in GitHub Desktop.
Save ddnode/5269252 to your computer and use it in GitHub Desktop.
Markup free clearing
/**
* Markup free clearing
* Details: http://perishablepress.com/press/2009/12/06/new-clearfix-hack
*/
.clearfix:after {
content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;
}
* html .clearfix { height: 1%; } /* IE6 */
*:first-child + html .clearfix { min-height: 1%; } /* IE7 */
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment