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