SASS @import Directive

Advertisements

Prev Tutorial Next Tutorial

SASS @import Directive

@import directive is used to import the sass or scss files. It directly takes the filename to import. Suppose you have two scss first file is A.scss and second file is B.scss and you want to import A.scss into B.scss.

You can see below example;

A.scss

 html,  
body,
h1,
ul,  
ol {  
   margin: 0;  
  padding: 0;  
}  

B.scss

@import 'A';  
body {  
  font: 100% Helvetica, sans-serif;  
  background-color: cyan;  
}

Note: If the extension of the file is .scss or .sass the file will be imported. If there is no extension sass will try and find a file that matches the name and the proper extension. Syntax to import:

Syntax to import

  
@import "demo.scss";

@import "demo";

CSS file after processing

html, body, h1, ul, ol {  
  margin: 0;  
  padding: 0;  
}  
body {  
  font: 100% Helvetica, sans-serif;  
  background-color: cyan;  
}  

Prev Tutorial Next Tutorial

Advertisements

Buy This Ad Space @$20 per Month, Ad Size 600X200 Contact on: hitesh.xc@gmail.com or 8076671483

Pure VPN Privide Lowest Price VPN Just @ $1.65. Per Month with Non Detected IP Lowest Price Non Detected IP VPN

Magenet is best Adsense Alternative here we earn $2 for single link, Here we get links ads. Magenet

Download Projects

Advertisements


Buy Websites 9999595223

Buy Fresh and Payment Receive Media.net Account with Website. Contact on: hitesh.xc@gmail.com or 9999595223 Try this Keyword C++ Programs