Book Image

Sass Essentials

By : Alex Libby
Book Image

Sass Essentials

By: Alex Libby

Overview of this book

<p>Sass is a professional grade CSS extension language known for its stability and versatility in the field of web design. It introduces new concepts to CSS, such as variables and nesting, that allow users to speed up their workflows and make their code more dynamic.</p> <p>Sass Essentials is a fast-paced, hands-on guide that breaks down the mysteries of preprocessing CSS styles using the Sass preprocessor and shows you how you can apply simple techniques to quickly and efficiently create CSS style sheets.</p> <p>With this book, you will dive in and familiarize yourself with some popular directives and see how, with some care and planning, they can prove to be really powerful tools to use in Sass.</p>
Table of Contents (12 chapters)

Making a start on our code


We started this book by preparing our environment—now that everything is installed, we can look at writing some code.

Of course, we can jump in, but as you are likely to be relatively new to working with Sass, it's a wise idea to get as much help as possible. One way to achieve this is through the use of linting code or running a continual background check to ensure that we are writing valid Sass code.

The great thing about this is that we can easily set this up with the addition of Ruby gems. These are the Ruby equivalent to plugins and work in a similar fashion to using standard plugins such as those we may use when working with jQuery. The plugin we will use is scss-lint, which is available at https://github.com/brigade/scss-lint. Let's take a look at how to set this up from within Sublime Text, using the SublimeLinter SCSS plugin from https://github.com/attenzione/sublimeLinter-scss-lint.

Note

This exercise assumes that you have Package Control and Sass support...