Joined December 2012
·

Simon Sturgess

Posted to Clearing floats, the alternative way over 1 year ago

Or even better create a class of cf and then use a pseudo element to clear the floats. So the container holding the floats has a class of cf and in your styles use:

.cf:after {
content:"";
clear:both;
display:block;
}

Nice, but I would use CSS animations over jQuery ones to help improve performance. Although it requires a little more work to calculate heights etc. as slideDown() does all that for you.

Achievements
11 Karma
0 Total ProTip Views