O'Reilly logo

Pragmatic Guide to Sass by Michael Lintorn Catlin, Hampton Catlin

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

33Jazzing Up Layouts with Columns

Say we want to make our website look more like a newspaper. We want to turn our boring one-column paragraph into multiple columns. This is a lot easier with Compass.

We have the option to apply any number of columns. We can use two extra mixins to define the width of each column as well as the gap between each column.

If necessary, we can add a line to separate the columns of text. The declarations we use are the same as what we would use for describing a regular border, namely the width, style, and color.

It’s important to note that columns aren’t really supported in older versions of Internet Explorer. Also, the column attribute doesn’t really like it if you define heights.

What To Do...
  • Turn text into columned ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required