|
module.exports = require('native-fetch') |
When using the browser compile of this, the system ultimately imports "native-fetch" but the API of native-fetch doesn't have fetch as the default export, but rather as { fetch } on the exports.
The implementation is here https://github.com/achingbrain/native-fetch/blob/master/src/index.js
So either this code should be changed to not use default here
|
const { Response, Request, Headers, default: fetch } = require('../fetch') |
Or request native-fetch to export fetch as default in addition to { fetch }
js-ipfs-utils/src/fetch.browser.js
Line 10 in 5eecdcb
When using the browser compile of this, the system ultimately imports "native-fetch" but the API of native-fetch doesn't have fetch as the default export, but rather as { fetch } on the exports.
The implementation is here https://github.com/achingbrain/native-fetch/blob/master/src/index.js
So either this code should be changed to not use default here
js-ipfs-utils/src/http/fetch.browser.js
Line 5 in 5eecdcb
Or request native-fetch to export fetch as default in addition to { fetch }