Answers for "using sass in html"

5

how to use scss in html

/* Answer to: "how to use scss in html" */

/*
  Unfortunately, you can't directly insert an SCSS (Sassy CSS) file
  into your HTML. That's because SASS is a superset (or so-called
  preprocessor or extension) of CSS3's syntax, which is NOT
  supported by web browsers.

  To take full advantage of all the incredible features offered by
  SCSS in your HTML page, you’ll first have to compile it down
  to CSS.

  For more information, check out the answers in:
  https://www.quora.com/How-do-I-insert-an-SCSS-file-into-HTML
*/
Posted by: Guest on April-20-2020
0

include sass in html

You have to use a build tool like Gulp which will convert the SASS file to CSS file , then you just have to link the CSS file in your HTML.
What’s interesting is that you don’t have to do this everytime you make a change in your SASS file. Gulp has a watch function which monitors the SASS files for changes and generate CSS file on the fly.
To use SASS with gulp , follow this tutorial - http://ryanchristiani.com/getting-started-with-gulp-and-sass/

Aditya Agarwal
Posted by: Guest on July-05-2021
0

scss

sass --watch input.scss output.css
Posted by: Guest on August-11-2020

Browse Popular Code Answers by Language