developit / developit/web-worker

Running through rollup for node causes issues with dynamic require

Đang mở
#6 11 bình luận 4 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
JavaScript
Star
1.2k
Fork
57
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Thanks for a neat little library!

I was attempting at incorporating it into a library of mine which I bundle using rollup and I get an issue
````
Error: Dynamic requires are not currently supported by rollup-plugin-commonjs
````
which was related to [this line of your library](
https://github.com/developit/web-worker/blob/master/node.js#L190)

From what I can tell it looks like it's to do with requiring the URL of the worker?

Anyway just thought I'd flag it as other users of rollup may run into the same issue.

Cheers
Rowan

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.