Module

x/oak/util.ts>readableStreamFromReader

A middleware framework for handling HTTP with Deno, Node, Bun and Cloudflare Workers 🐿️ 🦕
Extremely Popular
Go to Latest
function readableStreamFromReader
import { readableStreamFromReader } from "https://dotland.deno.dev/x/oak@14.2.0/util.ts";

Create a ReadableStream<Uint8Array> from a Deno.Reader.

When the pull algorithm is called on the stream, a chunk from the reader will be read. When null is returned from the reader, the stream will be closed along with the reader (if it is also a Deno.Closer).