josdejong / workerpool

Offload tasks to a pool of workers on node.js and in the browser
Apache License 2.0
2.06k stars 147 forks source link

Refactor/rollup #403

Closed KonghaYao closed 10 months ago

KonghaYao commented 11 months ago

In this pull request, I have switched the bundling tool in the project to Rollup and performed the necessary bundling and testing. The goal was to ensure that the generated output files remain identical to the previous build.

To achieve this, I had to modify the relevant code sections related to “Fool Webpack”, as it used certain techniques that caused failures during Vite and other tool bundling.

josdejong commented 11 months ago

This is awesome! Thanks for your PR @KonghaYao, I'm really happy to be able to get rid of gulp and webpack.

I'll check your PR soon (already made one small remark).

KonghaYao commented 11 months ago

I want to write some examples about bundlers like Vite, to test their runtime behavior in the browser. I will create an another PR later.

josdejong commented 10 months ago

Thanks @KonghaYao , your Rollup replacement works like a charm, this is impressive! It is nice to see that requireFoolWebpack has become redundant now 😄. And I see the minified bundles are a bit smaller than before, that's always good.

I think there are no breaking changes, but I'll publish this as a major release because the changed bundle may have introduced subtle changes that for example Webpack applications may be relying on.

I'll also change the version numbers of the devDependencies in package.json to exact numbers, so installing and building workerpool anywhere is guaranteed to give the exact same result.

josdejong commented 10 months ago

I've now publish v7.0.0.