Skip to content

fix: use native fetch if available#62

Merged
achingbrain merged 8 commits intomasterfrom
fix/use-native-fetch-if-available
Oct 10, 2020
Merged

fix: use native fetch if available#62
achingbrain merged 8 commits intomasterfrom
fix/use-native-fetch-if-available

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