#46 Exchanged uglify-es with terser in gulpfile and fixed formatting

This commit is contained in:
Serraniel 2020-09-11 20:57:15 +02:00
parent 1726b3fd84
commit 9cf3ace1d3
Signed by: Serraniel
GPG key ID: 3690B4E7364525D3

View file

@ -1,7 +1,7 @@
const gulp = require('gulp');
const cssnano = require('cssnano')
const gulpLoadPlugins = require('gulp-load-plugins')
const uglify = require('gulp-uglify-es').default;
const terser = require('terser');
const del = require('del');
const browserify = require('browserify');
const babelify = require('babelify');
@ -118,7 +118,7 @@ gulp.task('scripts', () => {
.pipe(source('app.js'))
.pipe(buffer())
.pipe($.if(isDev, $.sourcemaps.init({ loadMaps: true })))
.pipe(uglify({ compress: { drop_console: isProd, drop_debugger: isProd } }))
.pipe($.terser({ compress: { drop_console: isProd, drop_debugger: isProd } }))
.pipe($.rename({ suffix: '.min' }))
.pipe($.size({
showFiles: true,