How to compile SASS into CSS and watch for changes?

Compiling a SASS file

Let’s say we have a folder structure something like this:

-> styles/

-> styles/
-> style.scss
sass src/styles:public/styles
sass style.scss style.css
sass src/styles:src/styles

Watching for changes in SASS

Just add a --watch flag in the command to watch the changes made to the Sass file in src/styles directory.

sass --watch src/styles:public/styles



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store


Full Stack Developer | Content Creator | Technical Writer