Exports as Tasks

Using the ES2015 module syntax you can use your exports as tasks.

import gulp from 'gulp';
import babel from 'gulp-babel';

// named task
export function build() {
  return gulp.src('src/*.js')

// default task
export default function dev() {
  gulp.watch('src/*.js', ['build']);

This will not work with the gulp-cli version bundled with gulp 3.x. You must use the latest published version.

results matching ""

    No results matching ""