You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
722 B
JavaScript

'use strict';
var loggerPartial = require("@joepie91/gulp-partial-logger");
var livereloadPartial = require("@joepie91/gulp-partial-livereload");
var cache = require("gulp-cached");
var sass = require("gulp-sass");
module.exports = function () {
var options = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0];
var cacheKey = options.cacheKey != null ? options.cacheKey : "preset";
var streamList = [];
if (cacheKey !== false) {
streamList.push(cache(cacheKey));
}
streamList.push(sass());
if (options.livereload != null) {
streamList.push(livereloadPartial(options.livereload));
}
return loggerPartial("scss", streamList, {
logger: {
basePath: options.basePath
}
});
};