TomNix / Gulp-Practice

A repo for reference and practice of using Gulp taskrunner and common gulp tasks

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Gulp Taskrunner Repo

This will serve as a reference repository for common setup and tasks using Gulp taskrunner.



Preparing Gulp

  • Create package.json (using npm init generally)
  • Install gulp locally and globally (npm i --save-dev gulp)
  • Create a src directory
    • This is where all files that will be used for gulp will go
    • A dist folder will be created for post-compilation output
    • (src and dist are not required folder names)
  • Create a gulpfile (gulpfile.js)
  • Require gulp (const gulp = require('gulp');)

Top Level Tasks

Follows structure of gulp.task(taskName: String, callback(){});

Run with gulp taskName

  • gulp.task - Define tasks
  • gulp.src - Point to files for use
  • gulp.dest - Point to folder destination of post-compilation files
  • gulp.watch - Watch files/folders for changes

About

A repo for reference and practice of using Gulp taskrunner and common gulp tasks


Languages

Language:JavaScript 100.0%