Skip to content
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

electron-fetch dependency is not ESM compatible #164

Closed
TheDutchCoder opened this issue Jan 12, 2022 · 1 comment
Closed

electron-fetch dependency is not ESM compatible #164

TheDutchCoder opened this issue Jan 12, 2022 · 1 comment
Labels
need/triage Needs initial labeling and prioritization

Comments

@TheDutchCoder
Copy link

This issue originated on the js-ipfs repo, where a bug was reported that the library wouldn't properly run with Vite, as electron somehow got required (ipfs/js-ipfs#4011 (comment)).

After some diging, I found that electron-fetch is a dependency in this (js-ipfs-utils) library and that is a Node library, importing things like url and http, which are not usable in a browser.

I think for the ESM build of this package, electron-fetch shouldn't be included at all, but I'm not too familiar with how the different builds (in combination with environments) work.

@TheDutchCoder TheDutchCoder added the need/triage Needs initial labeling and prioritization label Jan 12, 2022
@ipfs ipfs deleted a comment from welcome bot Jan 14, 2022
@lidel
Copy link
Member

lidel commented Jan 14, 2022

Generic fix / continued in #154

@lidel lidel closed this as completed Jan 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
need/triage Needs initial labeling and prioritization
Projects
None yet
Development

No branches or pull requests

2 participants