Closed poppa closed 4 years ago
Oh, one thing I forgot to mention is that the [object Object]
error message was happening when using Webpack 5.
In Webpack 4 the jsonStats.errors
array is an array of strings.
This fix doesn't change the behaviour with Webpack 4 though, from what I have tested.
Thanks!
Any chance to get this change released? We started using webpack 5 with webpack-stream
which works like a charm, but if webpack fails it's difficult to debug because without the changes submitted here, errors are obfuscated.
@snoack Sorry thought I already did. Released as 6.1.1
.
Error messages from jsonStats errors was constructed by
errors.join('\n')
which resulted in a message like[object Object]
.This fix tries to resolve the actual error message from error objects via some naive heuristics