Automate your LESS/SCSS task and bundle your JS scripts with GulpJS.
We need Node.js to run Gulp. Node.js can be download from https://nodejs.org/en/.
Open the command prompt in your system and enter following command.
node -v
This will display the installed Node.js version.
npm -v
The version of npm which is used to install modules.
When you’re done with installing Node, Download Project from GitHub or clone project to your machine.
git clone https://github.com/03bgls25/gulp-less-scss-js.git
Now install npm packages listed on package.json file by using following command in the command prompt. Adding “–g” flag ensure that the Gulp is globally available for any project.
npm install
Open gulpfile.js file. Then you can configure you project directory of source and destination path by changing var config.
var config = { paths: { src: { scss: './src/scss/', less: './src/less/', scripts: './src/scripts/', }, dest: './docs/', }, serve: { proxy: '', server: './docs/' } };
You can run your Gulp project by entering following command
gulp
gulp serve