Browse Source

Fixed outputting errors from webpack/babel-loader

flowchartTest
jos 9 years ago
parent
commit
3ddd43adba
1 changed files with 12 additions and 3 deletions
  1. +12
    -3
      gulpfile.js

+ 12
- 3
gulpfile.js View File

@ -52,9 +52,9 @@ var webpackConfig = {
wrappedContextRegExp: /$^/ wrappedContextRegExp: /$^/
}, },
plugins: [ bannerPlugin ], plugins: [ bannerPlugin ],
cache: true,
debug: true,
bail: true
cache: true
//debug: true,
//bail: true
}; };
var uglifyConfig = { var uglifyConfig = {
@ -79,8 +79,17 @@ gulp.task('bundle-js', ['clean'], function (cb) {
compiler.run(function (err, stats) { compiler.run(function (err, stats) {
if (err) { if (err) {
gutil.log(err.toString()); gutil.log(err.toString());
}
// output soft errors
stats.compilation.errors.forEach(function (err) {
gutil.log(err);
});
if (err || stats.compilation.errors.length > 0) {
gutil.beep(); // TODO: this does not work on my system gutil.beep(); // TODO: this does not work on my system
} }
cb(); cb();
}); });
}); });

Loading…
Cancel
Save