developit / web-worker

Consistent Web Workers in browser and Node.
https://npm.im/web-worker
Apache License 2.0
1.05k stars 55 forks source link

fix: improve cjs esm compatibility #47

Open martines3000 opened 5 months ago

martines3000 commented 5 months ago

Fixes: #46 and also #36 and #44

SnickerChar commented 5 months ago

Will this fix #44 as well do you think?

martines3000 commented 5 months ago

Will this fix #44 as well do you think?

Yes, this PR also resolves that issue. There was another issue now ReferenceError: __filename is not defined in ES module scope, but I fixed this in latest commit.

Thank you for making me aware of that, it helped me catch the bug 👍 .

martines3000 commented 5 months ago

I also fixed a wrong import in tests and small lint issue that was introduced by me. Now it should be better.

martines3000 commented 5 months ago

@developit When you get the time, please check out the PR as it should resolve quite a lot of issues. Thank you in advance 💯 .

EmilIvanichkovv commented 5 months ago

Possibly a fix for https://github.com/developit/web-worker/issues/48 too

DanielSchiavini commented 3 weeks ago

The build is broken for 7 months in this PR isn't reviewed after 4 months. Maybe time to fork this :cry: