Update postcss task
This commit is contained in:
parent
268cbed282
commit
29354f0920
|
|
@ -1,22 +1,24 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
var gulp = require('gulp'),
|
const gulp = require('gulp'),
|
||||||
postcss = require('gulp-postcss'),
|
postcss = require('gulp-postcss'),
|
||||||
autoprefixer = require('autoprefixer');
|
autoprefixer = require('autoprefixer');
|
||||||
|
|
||||||
function postcssTask(options){
|
function postcssTask(options){
|
||||||
gulp.task('postcss', ['dupe'], function () {
|
// Requires: dupe.
|
||||||
var processors = [
|
gulp.task(
|
||||||
autoprefixer({
|
'postcss',
|
||||||
browsers: ['last 5 versions']
|
function() {
|
||||||
})
|
var processors = [
|
||||||
];
|
autoprefixer()
|
||||||
|
];
|
||||||
|
|
||||||
return options
|
return options
|
||||||
.src(options.workingDir + '/**/*.css')
|
.src(options.workingDir + '/**/*.css')
|
||||||
.pipe(postcss(processors))
|
.pipe(postcss(processors))
|
||||||
.pipe(gulp.dest(options.workingDir));
|
.pipe(gulp.dest(options.workingDir));
|
||||||
});
|
}
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = postcssTask;
|
module.exports = postcssTask;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue