-
Notifications
You must be signed in to change notification settings - Fork 0
/
gulpfile.js
34 lines (27 loc) · 850 Bytes
/
gulpfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
var gulp = require('gulp');
var sass = require('gulp-sass');
var browserSync = require('browser-sync').create();
var autoprefixer = require('gulp-autoprefixer');
gulp.task('sass', function () {
gulp.src('./scss/styles.scss')
.pipe(sass().on('error', sass.logError))
.pipe(autoprefixer({
browsers: ['last 5 versions','> 1%',
'ie 8',
'ie 9',
'ios 6',
'android 4'],
cascade: true
}))
.pipe(gulp.dest('./css'))
.pipe(browserSync.reload({
stream: true
}))
});
gulp.task('default', function() {
browserSync.init({
server: "./"
});
gulp.watch("./scss/styles.scss", ['sass']);
gulp.watch("./*.html").on('change', browserSync.reload);
});