Streams API
The Streams API allows JavaScript to programmatically access streams of data received over the network or created by JavaScript, and process them chunk by chunk. This enables efficient processing of large data without having to load everything into memory at once.
ReadableStream
Create and consume streams of data one chunk at a time. ReadableStreams are perfect for handling large files, network responses, or any data that arrives over time, allowing you to start processing information immediately rather than waiting for everything to download.
Output
Click Run to see output...
TransformStream
Process and modify data as it flows through a stream pipeline. TransformStreams act like filters that can convert, compress, decrypt, or otherwise change data on-the-fly without needing to load everything into memory, making them ideal for efficient data processing.
Output
Click Run to see output...