title as a second parameter
Hurtak opened this issue · comments
It would be helpful, if we could set title as second parameter, so we could do something like this:
var conf = {
size: {} // some general configuration we want to use for all instances
}
gulp.task('compile:client', function() {
var assets = $.useref.assets();
return gulp.src('./app/**/*.html')
.pipe(assets)
.pipe($.if('*.css', $.less()))
.pipe($.if('*.css', $.size(conf.size, 'css'))) // <--
.pipe($.if('*.js', $.size(conf.size, 'js'))) // <--
.pipe(assets.restore())
.pipe($.useref())
.pipe(gulp.dest('./dist'));
});
I can send pull request if you would agree with this api extension.
Nah, I don't want to complicate the API. Just wrap it in a function that returns the object if you need to reuse something.