nx.js
Classes

ReadableStream

This Streams API interface represents a readable stream of byte data. The Fetch API offers a concrete instance of a ReadableStream through the body property of a Response object.

MDN Reference

Type Parameters

Type ParameterDefault type
Rany

Implements

Constructors

new ReadableStream()

new ReadableStream<R>(underlyingSource, strategy?): ReadableStream<R>

Parameters

ParameterType
underlyingSourceUnderlyingByteSource
strategy?object
strategy.highWaterMark?number

Returns

ReadableStream<R>

new ReadableStream()

new ReadableStream<R>(underlyingSource, strategy?): ReadableStream<R>

Parameters

ParameterType
underlyingSourceUnderlyingDefaultSource<R>
strategy?QueuingStrategy<R>

Returns

ReadableStream<R>

new ReadableStream()

new ReadableStream<R>(underlyingSource?, strategy?): ReadableStream<R>

Parameters

ParameterType
underlyingSource?UnderlyingSource<R>
strategy?QueuingStrategy<R>

Returns

ReadableStream<R>

Properties

PropertyModifierTypeDescription
lockedreadonlybooleanMDN Reference

Methods

[asyncIterator]()

[asyncIterator](options?): ReadableStreamAsyncIterator<R>

Parameters

ParameterType
options?ReadableStreamIteratorOptions

Returns

ReadableStreamAsyncIterator<R>

Implementation of

globalThis.ReadableStream.[asyncIterator]


cancel()

cancel(reason?): Promise<void>

MDN Reference

Parameters

ParameterType
reason?any

Returns

Promise<void>

Implementation of

globalThis.ReadableStream.cancel


getReader()

getReader(options)

getReader(options): ReadableStreamBYOBReader

MDN Reference

Parameters
ParameterType
optionsobject
options.mode"byob"
Returns

ReadableStreamBYOBReader

Implementation of

globalThis.ReadableStream.getReader

getReader()

getReader(): ReadableStreamDefaultReader<R>

MDN Reference

Returns

ReadableStreamDefaultReader<R>

Implementation of

globalThis.ReadableStream.getReader

getReader(options)

getReader(options?): ReadableStreamReader<R>

MDN Reference

Parameters
ParameterType
options?ReadableStreamGetReaderOptions
Returns

ReadableStreamReader<R>

Implementation of

globalThis.ReadableStream.getReader


pipeThrough()

pipeThrough<T>(transform, options?): ReadableStream<T>

MDN Reference

Type Parameters

Type Parameter
T

Parameters

ParameterType
transformReadableWritablePair<T, R>
options?StreamPipeOptions

Returns

ReadableStream<T>

Implementation of

globalThis.ReadableStream.pipeThrough


pipeTo()

pipeTo(destination, options?): Promise<void>

MDN Reference

Parameters

ParameterType
destinationWritableStream<R>
options?StreamPipeOptions

Returns

Promise<void>

Implementation of

globalThis.ReadableStream.pipeTo


tee()

tee(): [ReadableStream<R>, ReadableStream<R>]

MDN Reference

Returns

[ReadableStream<R>, ReadableStream<R>]

Implementation of

globalThis.ReadableStream.tee


values()

values(options?): ReadableStreamAsyncIterator<any>

MDN Reference

Parameters

ParameterType
options?ReadableStreamIteratorOptions

Returns

ReadableStreamAsyncIterator<any>

Implementation of

globalThis.ReadableStream.values

On this page