mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
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`
This commit is contained in:
parent
5a42a4181a
commit
9079c1110a
@ -155,7 +155,8 @@ function transformToUmd(files, dest) {
|
|||||||
.pipe(babel({
|
.pipe(babel({
|
||||||
presets: ['es2015'],
|
presets: ['es2015'],
|
||||||
moduleId: 'ss.' + path.parse(file).name,
|
moduleId: 'ss.' + path.parse(file).name,
|
||||||
plugins: ['transform-es2015-modules-umd']
|
plugins: ['transform-es2015-modules-umd'],
|
||||||
|
comments: false
|
||||||
}))
|
}))
|
||||||
.on('error', notify.onError({
|
.on('error', notify.onError({
|
||||||
message: 'Error: <%= error.message %>',
|
message: 'Error: <%= error.message %>',
|
||||||
@ -184,7 +185,8 @@ gulp.task('bundle-leftandmain', function bundleLeftAndMain() {
|
|||||||
}))
|
}))
|
||||||
.transform(babelify.configure({
|
.transform(babelify.configure({
|
||||||
presets: ['es2015'],
|
presets: ['es2015'],
|
||||||
ignore: /(thirdparty)/
|
ignore: /(thirdparty)/,
|
||||||
|
comments: false
|
||||||
}))
|
}))
|
||||||
.on('log', function (msg) { gulpUtil.log('Finished bundle-leftandmain.js ' + msg); })
|
.on('log', function (msg) { gulpUtil.log('Finished bundle-leftandmain.js ' + msg); })
|
||||||
.on('update', bundleLeftAndMain)
|
.on('update', bundleLeftAndMain)
|
||||||
@ -210,7 +212,8 @@ gulp.task('bundle-lib', function bundleLib() {
|
|||||||
}))
|
}))
|
||||||
.transform(babelify.configure({
|
.transform(babelify.configure({
|
||||||
presets: ['es2015'],
|
presets: ['es2015'],
|
||||||
ignore: /(thirdparty)/
|
ignore: /(thirdparty)/,
|
||||||
|
comments: false
|
||||||
}))
|
}))
|
||||||
.on('log', function (msg) { gulpUtil.log('Finished bundle-lib.js ' + msg); })
|
.on('log', function (msg) { gulpUtil.log('Finished bundle-lib.js ' + msg); })
|
||||||
.on('update', bundleLib)
|
.on('update', bundleLib)
|
||||||
|
Loading…
Reference in New Issue
Block a user