Read more

CSS has a built-in clearfix

Henning Koch
August 05, 2021Software engineer at makandra GmbH

The need for clearfix hacks Show archive.org snapshot has been greatly reduced since we could layout with Flexbox or CSS Grid.

Illustration web development

Do you need DevOps-experts?

Your development team has a full backlog? No time for infrastructure architecture? Our DevOps team is ready to support you!

  • We build reliable cloud solutions with Infrastructure as code
  • We are experts in security, Linux and databases
  • We support your dev team to perform
Read more Show archive.org snapshot

However, when you do need a clearfix, there's no reason to use a hack anymore. You can just give the clearing container display: flow-root Show archive.org snapshot .

This is supported by all browsers except IE11 Show archive.org snapshot .

Posted by Henning Koch to makandra dev (2021-08-05 13:03)