W3cubDocs

/Web APIs

DecompressionStream

The DecompressionStream interface of the Compression Streams API is an API for decompressing a stream of data.

Constructor

DecompressionStream()

Creates a new DecompressionStream

Instance properties

DecompressionStream.readable

Returns the ReadableStream instance controlled by this object.

DecompressionStream.writable

Returns the WritableStream instance controlled by this object.

Examples

In this example a blob is decompressed using gzip compression.

js

const ds = new DecompressionStream("gzip");
const decompressedStream = blob.stream().pipeThrough(ds);

Specifications

Browser compatibility

Desktop Mobile
Chrome Edge Firefox Internet Explorer Opera Safari WebView Android Chrome Android Firefox for Android Opera Android Safari on IOS Samsung Internet
DecompressionStream 80 80 113 No 67 16.4 80 80 113 57 16.4 13.0
DecompressionStream 80 80 113 No 67 16.4 80 80 113 57 16.4 13.0
readable 80 80 113 No 67 16.4 80 80 113 57 16.4 13.0
writable 80 80 113 No 67 16.4 80 80 113 57 16.4 13.0

© 2005–2023 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/DecompressionStream