From 9079c1110a6e5ecd01a9dd1771c8ce17347b94de Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Tue, 23 Feb 2016 11:12:24 +1300 Subject: [PATCH] Don't add comments to dist files via babelify We've had some issues with different dependencies causing different results based on the environment, which in turn causes unnecessary diffs - making our work harder to review. Comments can be read through the ES6 source files, and through source maps when generated through `npm run build --development` --- gulpfile.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index c2f4f9793..d9dfad842 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -155,7 +155,8 @@ function transformToUmd(files, dest) { .pipe(babel({ presets: ['es2015'], moduleId: 'ss.' + path.parse(file).name, - plugins: ['transform-es2015-modules-umd'] + plugins: ['transform-es2015-modules-umd'], + comments: false })) .on('error', notify.onError({ message: 'Error: <%= error.message %>', @@ -184,7 +185,8 @@ gulp.task('bundle-leftandmain', function bundleLeftAndMain() { })) .transform(babelify.configure({ presets: ['es2015'], - ignore: /(thirdparty)/ + ignore: /(thirdparty)/, + comments: false })) .on('log', function (msg) { gulpUtil.log('Finished bundle-leftandmain.js ' + msg); }) .on('update', bundleLeftAndMain) @@ -210,7 +212,8 @@ gulp.task('bundle-lib', function bundleLib() { })) .transform(babelify.configure({ presets: ['es2015'], - ignore: /(thirdparty)/ + ignore: /(thirdparty)/, + comments: false })) .on('log', function (msg) { gulpUtil.log('Finished bundle-lib.js ' + msg); }) .on('update', bundleLib)