webpack-contrib / webpack-hot-middleware

Webpack hot reloading you can attach to your own server
MIT License
2.34k stars 296 forks source link

feat: improve logic for handling multicomplier stats result to accomodate webpack5 #429

Closed eokoneyo closed 2 years ago

eokoneyo commented 2 years ago

This PR contains a:

Motivation / Use-Case

This PR aims to address an issue I think is related to #390,

Details of my system setup;

I had a similar issue on further investigation, I realized that the problem happens because the shape of stats object returned in Webpack 5 differs from that of Webpack 4. See here.

This PR checks the returned stats object for the stats property on the returned statsResult which also present on multicomplier stats results generated from Webpack, the returned stats is handled as such if this is the case, from there on everything works like it should.

Breaking Changes

Additional Info

linux-foundation-easycla[bot] commented 2 years ago

CLA Signed

The committers listed above are authorized under a signed CLA.

eokoneyo commented 2 years ago

Can you add tests case and accept CLA? thank you

@alexander-akait I added tests cases and accepted the CLA.

glenjamin commented 2 years ago

@glenjamin Hellom can I take care about webpack-hot-middleware, becauwe we have a lot of PRs and issues, I want to start to fix them and in future union webpack-dev-server/webpack-dev-middleware and webpack-hot-middleware in the one repo, and reuse the same code for better maintanance

Yep, please go ahead - I've not been actively planning anything

alexander-akait commented 2 years ago

@eokoneyo Thank you