RangerMauve / js-ipfs-fetch

Use the same `fetch()` API browsers provide for HTTP, but for IPFS
https://youtu.be/kI9Issf3MNc?t=1606
MIT License
64 stars 7 forks source link

getReader() is not available. #3

Closed ikreymer closed 3 years ago

ikreymer commented 3 years ago

To be compatible with browser fetch (related to #1) and ReadableStream, it should be possible to do:

const response = await fetch("ipfs://...")
const reader = response.body.getReader();

Currently, getReader() is not a function.

RangerMauve commented 3 years ago

Yeah, I think we could integrate WHATWG streams there.

RangerMauve commented 3 years ago

Thank you for your patience, fixed in 1.3.0. Should be an actual readable stream now.