Review: SASS for Web Designers

SASS for Web Designers by Dan Cederholm is from A Book Apart (2013). Like all the A Book Apart books, it’s brief and very good. And like all books from A Book Apart, it isn’t available new from anyone but them.

SASS is a CSS preprocessor. The book’s first chapter is Why SASS? Cederholm does the explaining with this elevator pitch:

Ever needed to change, say, a color in your stylesheet, and found that you had to find and replace the value multiple times? What if you could change that value in one place and the entire stylesheet reflected that change? You can with SASS! Or how about repeated blocks of styles that are used in various locations throughout the stylesheet? That’s also SASS!

From the first page, you see code examples for how something would be written in SASS. Following that, the CSS output from SASS is shown, to explain exactly what the SASS example does. You quickly begin to see the connection between what you’re asking the preprocessor to do and the CSS output.

Chapter 1 also explains SASS syntax and using the .scss file extension.

Chapter 2 is Workflow. It explains how to install SASS on a Mac and/or Windows. It gives you a few (very few) command line entries but also mentions some apps you can use if the command line freaks you out. Finally it explains how to choose an output style for the CSS that SASS is going to spit out.

Chapter 3 is Using SASS. You learn about nesting rules and namespace properties, about referencing parent selectors with &, about commenting in SASS, about variables and mixins, about mixin arguments. Cederholm also explains mixin libraries and the use of @import rule. He discusses the pros and cons of the Compass framework and the Bourbon library.

He explains extends, multiple extends, and extend vs. mixin. Every one of the topics in chapter 3 comes with very clear code examples that help you see how to do something with SASS and what the results would be in CSS.

Chapter 4 is Media Queries. You find out about nesting media queries, using variables for breakpoints, using the content directive, and putting mixins inside mixins.

The book wraps up with a list of resources for learning more.

A review by Virginia DeBolt of SASS for Web Designers (rating: 5 stars)

Summary: You could start using SASS today with this book as a guide.

Leave a Reply