minify svg mod

This commit is contained in:
infeeeee
2019-09-11 12:14:41 +02:00
parent b296bca869
commit bcaffeeff8
23 changed files with 31 additions and 180 deletions

View File

@@ -17,9 +17,9 @@ gulp.task('sass', function () {
});
gulp.task('liverel', function () {
return gulp.src(['./**','!./node_modules/**'])
return gulp.src(['./**', '!./node_modules/**'])
.pipe(livereload({
quiet:true
quiet: true
}))
})
@@ -30,11 +30,15 @@ gulp.task('liverel', function () {
gulp.task('watch', function () {
livereload.listen()
gulp.watch('./sass/**/*.scss', gulp.series('sass'))
gulp.watch(['./**','!./node_modules/**'], gulp.series('liverel'))
gulp.watch(['./**', '!./node_modules/**'], gulp.series('liverel'))
});
gulp.task('minify-svg', function(){
gulp.task('minify-svg', function () {
return gulp.src('./imgmax/**/*.svg')
.pipe(svgmin())
.pipe(gulp.dest('./img'));
.pipe(svgmin({
plugins: [{
removeViewBox: false
}]
}))
.pipe(gulp.dest('./img'));
})