adding same browser sync support than in parent theme
This commit is contained in:
parent
2e641fcf80
commit
606132a45c
|
@ -32,6 +32,7 @@ var ignore = require('gulp-ignore');
|
||||||
var rimraf = require('gulp-rimraf');
|
var rimraf = require('gulp-rimraf');
|
||||||
var sourcemaps = require('gulp-sourcemaps');
|
var sourcemaps = require('gulp-sourcemaps');
|
||||||
var browserSync = require('browser-sync').create();
|
var browserSync = require('browser-sync').create();
|
||||||
|
var reload = browserSync.reload;
|
||||||
|
|
||||||
// Run:
|
// Run:
|
||||||
// gulp sass
|
// gulp sass
|
||||||
|
@ -62,7 +63,7 @@ gulp.task('cssnano', ['cleancss'], function(){
|
||||||
.pipe(cssnano({discardComments: {removeAll: true}}))
|
.pipe(cssnano({discardComments: {removeAll: true}}))
|
||||||
.pipe(sourcemaps.write('./'))
|
.pipe(sourcemaps.write('./'))
|
||||||
.pipe(gulp.dest('./css/'))
|
.pipe(gulp.dest('./css/'))
|
||||||
.pipe(browserSync.stream());
|
.pipe(reload({stream: true}));
|
||||||
});
|
});
|
||||||
|
|
||||||
gulp.task('cleancss', function() {
|
gulp.task('cleancss', function() {
|
||||||
|
|
Reference in New Issue