'use strict'; const loggerPartial = require("@joepie91/gulp-partial-logger"); const livereloadPartial = require("@joepie91/gulp-partial-livereload"); const cache = require("gulp-cached"); const jade = require("gulp-jade"); module.exports = function(options) { let cacheKey = (options.cacheKey != null) ? options.cacheKey : "preset"; let streamList = [ cache(cacheKey), jade() ]; if (options.livereload != null) { streamList.push(livereloadPartial(options.livereload)); } return loggerPartial("jade", streamList, { logger: { basePath: options.basePath } }); }