Creating the Building tasks
Now is the time to create our task using only NPM.
Before we begin, it is important to keep in mind that NPM has two special commands that are invoked directly, start and test. So we will use the run command to run all the other tasks we create.
Our goals in this section are to:
- Copy some files from the source directory to the client directory
- Verify errors in JavaScript files
- Compile SASS files from src/scss and save them in the client/css folder
- Optimize images from src/images/gallery to client/images/gallery
- Concatenate JavaScript files from src/scripts to client/js/scripts
Installing the dependencies
To accomplish these tasks, we need to install some Command Line Interface (CLI) tools:
- Open the terminal/shell and type the ...
Get Node.js 6.x Blueprints now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.