O'Reilly logo

Mastering Sass by Luke Watts

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

Setting up Gulp

The first thing we need to do to use Gulp in our project is install it in our dev-dependencies. We do this using npm install:

npm install --save-dev gulp

Once gulp is installed, our next step is changing our package.json file so our main script is gulpfile.js instead of index.js:

// mastering-sass-swag/package.json 
"main": "gulpfile.js", 

We're going to delete our config.rb file. Surprised? We'll, we're not going to be running commands like compass watch or compass compile so we won't need the config.rb file. Instead we're going to do everything from this point on through Gulp. So keeping config.rb would just confuse things:

rm config.rb

We can also delete index.js at this point for the same reasons:

rm index.js

Next we need to create ...

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