Gulp
The Gulp tasks we have at the moment are gulp sass:compile
, which compiles our Sass, gulp sass:watch
, which compiles our Sass and watches for changes, and finally gulp serve
, which boots up a server, opens a tab in the browser and loads our project into it (if there is not already a tab open on localhost:3000
), and then watches for changes to our SCSS files and html files and compiles our Sass and refreshes the browser.
This is the task that we'll use the most. So let's make it our default task. Open the gulpfile.js and add the following task:
/** * Default Task * * Runs `gulp serve` */ gulp.task('default', ['serve']);
Now we only need to use the command:
gulp
Run it from the command line and our serve
task will be run.
Adding jQuery
We'll require some small amount of JavaScript for some UI improvements for our design over the next few chapters. To ease some of this work we'll use jQuery. The easiest way is to simply link to it from a Content Delivery...