O'Reilly logo

Beginning CSS Preprocessors: With SASS, Compass.js, and Less.js by Anirudh Prabhu

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

CHAPTER 3

image

Advanced Sass

In the previous chapter, you looked into the installation procedure and essential components needed to work with Sass. In this chapter, you will look into the more advanced concepts of Sass.

This chapter explores the following aspects of Sass:

  • @import
  • @media
  • @extend
  • @at-root
  • Mixin directives
  • Function directives
  • Output style
  • Building your own grid system

@import

Sass also supports importing features similar to what is available in native CSS. But unlike CSS, which downloads CSS when an @import is encountered, Sass and SCSS files imported using the SASS @import rules will be merged and output as a single file after compilation.

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