Sass - @-Rules and Directives


Advertisements

The following table lists all the rules and directives which you can use in SASS.

S. No. Directives & Description
1 @import

It imports the SASS or SCSS files, it directly takes the filename to import.

2 @media

It sets the style rule to different media types.

3 @extend

@extend directive is used to share rules and relationships between selectors.

4 @at-root

@at-root directive is a collection of nested rules, which is able to make style block at root of the document.

5 @debug

@debug directive detects the errors and displays the SassScript expression values to the standard error output stream.

6 @warn

@warn directive is used to give cautionary advice about the problem; it displays the SassScript expression values to the standard error output stream.

7 @error

@error directive displays the SassScript expression value as fatal error.

Advertisements