Webpack-dev-server: how to Error event in Node APi

Created on 3 Nov 2016  路  3Comments  路  Source: webpack/webpack-dev-server

like this:

new WebpackDevServer(webpack(CONFIG)).on('error', function(err){
  Growl.notify(err.message)
})

Most helpful comment

do not worry, I created a new issue https://github.com/webpack/webpack-dev-server/issues/688

All 3 comments

var server = new WebpackDevServer(compiler, {...});
server.listen(8080, "localhost", function(err) {
  // do your thing
});

Note that the issue template very clearly says that questions should be asked on StackOverflow, so I'm closing this.

This function is not called every time an error occurs. and it is called only when the server can not start.

We need it to be called every time the assembly failed!
Immediately reopen the ticket!

do not worry, I created a new issue https://github.com/webpack/webpack-dev-server/issues/688

Was this page helpful?
0 / 5 - 0 ratings