async function *binaryStream(body) {
  const reader = body.getReader()
  /** @type {{id: Uint8Array, data: Uint8Array, rest: Uint8Array}} */
  let next = null
  let rest = new Uint8Array()

  while (next = await readOne(reader, rest)) {
    rest = next.rest
    yield {id: next.id, data: next.data}
  }

  reader.releaseLock()
}
/**
 * Parse a binary response stream into an async iterable of split buffers
 * @param {ReadableStream} body
 */
Parse a binary response stream into an async iterable of split buffers
@param {ReadableStream} body
Parse a binary response stream into an async iterable of split buffers @param { ReadableStream } body
async function *binaryStream(body) {
  const reader = body.getReader()
  let next = null
  let rest = new Uint8Array()
  while (next = await readOne(reader, rest)) {
    rest = next.rest
    yield {id: next.id, data: next.data}
  }
  reader.releaseLock()
}
async function * binaryStream ( body ) { const reader = body . getReader ( ) let next = null let rest = new Uint8Array ( ) while ( next = await readOne ( reader , rest ) ) { rest = next . rest yield { id : next . id , data : next . data } } reader . releaseLock ( ) }
Parse a binary response stream into an async iterable of split buffers
 @param {ReadableStream} body
Parse a binary response stream into an async iterable of split buffers @param { ReadableStream } body
/** @type {{id: Uint8Array, data: Uint8Array, rest: Uint8Array}} */