ReadableByteStreamController
Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.
The ReadableByteStreamController interface of the Streams API represents a controller allowing control of a ReadableStream's state and internal queue. Byte stream controllers are for byte streams.
Constructor
None. ReadableByteStreamController instances are created automatically during ReadableStream construction.
Properties
ReadableByteStreamController.byobRequestRead only-
Returns the current BYOB pull request.
ReadableByteStreamController.desiredSizeRead only-
Returns the desired size required to fill the stream's internal queue.
Methods
ReadableByteStreamController.close()-
Closes the associated stream.
ReadableByteStreamController.enqueue()-
Enqueues a given chunk in the associated stream.
ReadableByteStreamController.error()-
Causes any future interactions with the associated stream to error.
Examples
TBD.
Specifications
| Specification |
|---|
| Streams Standard # rbs-controller-class |
Browser compatibility
BCD tables only load in the browser