I want to apply a Gulp watcher to my LESS files so Gulp will create css files whenever a LESS file gets saved.
How can I do this? It doesn't seem to be correct/sufficient to write something like this:
var gulp = require("gulp");
var moreLess = require("gulp-more-less");
var concatCss = require("gulp-concat-css");
var lessInFolder = "./Less/**/*.less";
gulp.task("less", function ()
{
gulp.src(lessInFolder).pipe(moreless()).pipe(concatCss()).pipe(gulp.dest("./css"));
});
gulp.watch(lessInFolder, ["less"]);
Create a dedicated task for the watch function :
then use the visual studio
Task Runner Explorer
to execute (or bind) that task.