diff --git a/src/Bundler.js b/src/Bundler.js index 10a5baf7c02..b83c039495c 100644 --- a/src/Bundler.js +++ b/src/Bundler.js @@ -301,7 +301,11 @@ class Bundler extends EventEmitter { return this.mainBundle; } catch (err) { this.error = err; + logger.error(err); + + this.emit('buildError', err); + if (this.hmr) { this.hmr.emitError(err); }