Sizing Boxes (Back to the Future)

Posted: July 24, 2012 Comments

Sizing Boxes (Back to the Future) – destroy/dstorey.

I’ve been using box-sizing:border-box; more and more lately as it seems. Especially with the Bootstrap-inspired style guides I’ve been working on for client projects. There are a few times where it just makes sense, and I think once I’m beyond my habitual omission of the property, I’ll begin to use it more and more. I remember struggling with the box model quite a bit as I was learning CSS and I don’t think I was alone. While it ‘makes sense’ to me now, the alternate model is really attractive on the surface.

There’s more to it though, it’s important to know the pros and cons associated with using box-sizing:border-box;, and this article is a great overview of each.

Get my newsletter

Receive periodic updates right in the mail!
  • This field is for validation purposes and should be left unchanged.

Leave a Reply

Your email address will not be published.