ReadableStreamDefaultController

The ReadableStreamDefaultController interface of the Streams API represents a controller allowing control of a ReadableStream's state and internal queue.

MDN Reference

Properties

Link copied to clipboard

The desiredSize read-only property of the required to fill the stream's internal queue.

Functions

Link copied to clipboard
fun close()

The close() method of the ReadableStreamDefaultController interface closes the associated stream.

Link copied to clipboard
fun enqueue(chunk: R = definedExternally)

The enqueue() method of the ``js-nolint enqueue(chunk) `` - chunk - : The chunk to enqueue.

Link copied to clipboard
fun error(error: JsError = definedExternally)

The error() method of the with the associated stream to error.