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

fix: use native fetch if available #62

Merged
merged 8 commits into from
Oct 10, 2020

Conversation

achingbrain
Copy link
Member

If you are in the Electron Renderer process, native fetch is available but it's ignored because the renderer does not respect the browser field of package.json, so we end up with node-fetch that uses a browser polyfill of the node http api.

Instead use native fetch if it's available or node fetch if not.

If you are in the Electron Renderer process, native fetch is available
but it's ignored because the renderer does not respect the browser
field of package.json, so we end up with node-fetch that uses a
browser polyfill of the node http api.

Instead use native fetch if it's available or node fetch if not.
@achingbrain
Copy link
Member Author

This bubbles up to ipfs/js-ipfs#3251

@achingbrain achingbrain reopened this Aug 28, 2020
@achingbrain
Copy link
Member Author

Refs jacobheun/any-signal#5

@jacobheun jacobheun added status/blocked Unable to be worked further until needs are met and removed status/blocked Unable to be worked further until needs are met labels Sep 17, 2020
@achingbrain achingbrain merged commit 9b0ff2f into master Oct 10, 2020
@achingbrain achingbrain deleted the fix/use-native-fetch-if-available branch October 10, 2020 07:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants