Compression
Compression Streams Standard Compresses data in a streaming fashion using a specified algorithm.
Data written to the writable side is compressed and made available on the readable side. Supports "gzip", "deflate", "deflate-raw", and "br" (Brotli) formats.
Module:whatwg.compression
Support: Experimental
Since: 1.1.0
Docs: WHATWG Docs
Interface CompressionStream
Compresses data in a streaming fashion using a specified algorithm.
Data written to the writable side is compressed and made available on the readable side. Supports "gzip", "deflate", "deflate-raw", and "br" (Brotli) formats.
Since: 1.1.0 Docs: WHATWG Docs3 members: 3 undocumented
Constructors
Properties
---
Details
constructor(format)
new constructor(format: string)
new constructor(format: string)
| Parameter | Type | Description |
|---|---|---|
format | string | The compression format: "gzip", "deflate", "deflate-raw", or "br". |
TypeError--- If the format is not a supported compression algorithm.
readable
readable: ReadableStream
readable: ReadableStream
Throws:TypeError--- If the format is not a supported compression algorithm.
---
Interface DecompressionStream
Decompresses data in a streaming fashion using a specified algorithm.
Data written to the writable side is decompressed and made available on the readable side. Supports "gzip", "deflate", "deflate-raw", and "br" (Brotli) formats.
Since: 1.1.0 Docs: WHATWG Docs3 members: 3 undocumented
Constructors
Properties
---
Details
constructor(format)
new constructor(format: string)
new constructor(format: string)
| Parameter | Type | Description |
|---|---|---|
format | string | The compression format: "gzip", "deflate", "deflate-raw", or "br". |
TypeError--- If the format is not a supported compression algorithm.
readable
readable: ReadableStream
readable: ReadableStream
Throws:TypeError--- If the format is not a supported compression algorithm.
---