-
-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failed to import - webtorrent #450
Comments
torrent uses |
which in the packages browser field is resolved to false, browserfiy handed webtorrent just fine |
thanks, currently esm.sh doesn't respect |
also its sub dependencies, also browserify allowed custom fields like in the link above "chromeapp" so I guess we'd need a buildflag like target, something like import WebTorrent from 'https://esm.sh/webtorrent?target=deno'
import WebTorrent from 'https://esm.sh/webtorrent?target=browser'
import WebTorrent from 'https://esm.sh/webtorrent?target=chromeapp'
import WebTorrent from 'https://esm.sh/webtorrent?target=customfield' ? |
@ije is there any ETA from this? I understand that the browser field is already resolved and import aliases are already implemented in other places, seems like after v100 this only encountered more issues:
|
@ije v101 now has less errors or more like different ones, seems like the v101 prefix isn't getting embedded on polyfills? bittorrent-lsd.js:2 GET https://esm.sh/error.js?type=unsupported-nodejs-builtin-module&name=dgram&importer=bittorrent-lsd net::ERR_ABORTED 500
Uncaught TypeError: Failed to fetch dynamically imported module: https://esm.sh/v101/webtorrent@1.9.6
crypto-browserify.bundle.js:1 GET https://esm.sh/string_decoder@1.3.0/es2022/string_decoder.bundle.js net::ERR_ABORTED 500
crypto-browserify.bundle.js:1 GET https://esm.sh/events@3.3.0/es2022/events.bundle.js net::ERR_ABORTED 500
crypto-browserify.bundle.js:1 GET https://esm.sh/util@0.12.5/es2022/util.bundle.js net::ERR_ABORTED 500
crypto-browserify.bundle.js:1 GET https://esm.sh/crypto-browserify@3.12.0/es2022/crypto-browserify.bundle.js net::ERR_ABORTED 500
crypto-browserify.bundle.js:1 |
@ije v101 now has the same errors, seems like the v101 prefix isn't getting embedded on polyfills? bittorrent-lsd.js:2 GET https://esm.sh/error.js?type=unsupported-nodejs-builtin-module&name=dgram&importer=bittorrent-lsd net::ERR_ABORTED 500
Uncaught TypeError: Failed to fetch dynamically imported module: https://esm.sh/v101/webtorrent@1.9.6
crypto-browserify.bundle.js:1 GET https://esm.sh/string_decoder@1.3.0/es2022/string_decoder.bundle.js net::ERR_ABORTED 500
crypto-browserify.bundle.js:1 GET https://esm.sh/events@3.3.0/es2022/events.bundle.js net::ERR_ABORTED 500
crypto-browserify.bundle.js:1 GET https://esm.sh/util@0.12.5/es2022/util.bundle.js net::ERR_ABORTED 500
crypto-browserify.bundle.js:1 GET https://esm.sh/crypto-browserify@3.12.0/es2022/crypto-browserify.bundle.js net::ERR_ABORTED 500
crypto-browserify.bundle.js:1 |
haha sick, this package is trully a stress test for this kind of bundler |
Failing module
Error message
After
onload
I got this:Additional info
The text was updated successfully, but these errors were encountered: