Home › Forums › CSS › What is the best way of clearing floats in css? › Re: What is the best way of clearing floats in css?
January 25, 2013 at 7:56 pm
#122351
rosspenman
Participant
I usually use this one:
::after {
clear: both;
display: block;
content: “”;
}
In the event that I have already used up my `::after` pseudo-element, or I need to support ancient browsers, I would use `overflow: hidden;` or `overflow: auto;` depending on the situation.