diff --git a/doc/api/zlib.md b/doc/api/zlib.md index 76e1a31974ac85..a791cbc7387ded 100644 --- a/doc/api/zlib.md +++ b/doc/api/zlib.md @@ -382,7 +382,7 @@ These advanced options are available for controlling decompression: * Boolean flag enabling “Large Window Brotli” mode (not compatible with the Brotli format as standardized in [RFC 7932][]). -## Class: Options +## Class: `Options` @@ -445,35 +445,35 @@ const stream = zlib.createBrotliCompress({ }); ``` -## Class: zlib.BrotliCompress +## Class: `zlib.BrotliCompress` Compress data using the Brotli algorithm. -## Class: zlib.BrotliDecompress +## Class: `zlib.BrotliDecompress` Decompress data using the Brotli algorithm. -## Class: zlib.Deflate +## Class: `zlib.Deflate` Compress data using deflate. -## Class: zlib.DeflateRaw +## Class: `zlib.DeflateRaw` Compress data using deflate, and do not append a `zlib` header. -## Class: zlib.Gunzip +## Class: `zlib.Gunzip` Compress data using gzip. -## Class: zlib.Inflate +## Class: `zlib.Inflate` @@ -531,7 +531,7 @@ added: v0.5.8 Decompress either a Gzip- or Deflate-compressed stream by auto-detecting the header. -## Class: zlib.ZlibBase +## Class: `zlib.ZlibBase` @@ -572,7 +572,7 @@ The `zlib.bytesWritten` property specifies the number of bytes written to the engine, before the bytes are processed (compressed or decompressed, as appropriate for the derived class). -### zlib.close(\[callback\]) +### `zlib.close([callback])` @@ -581,7 +581,7 @@ added: v0.9.4 Close the underlying handle. -### zlib.flush(\[kind, \]callback) +### `zlib.flush([kind, ]callback)` @@ -598,7 +598,7 @@ perform flushing of any kind on the streams level. Rather, it behaves like a normal call to `.write()`, i.e. it will be queued up behind other pending writes and will only produce output when data is being read from the stream. -### zlib.params(level, strategy, callback) +### `zlib.params(level, strategy, callback)` @@ -612,7 +612,7 @@ This function is only available for zlib-based streams, i.e. not Brotli. Dynamically update the compression level and compression strategy. Only applicable to deflate algorithm. -### zlib.reset() +### `zlib.reset()` @@ -620,14 +620,14 @@ added: v0.7.0 Reset the compressor/decompressor to factory defaults. Only applicable to the inflate and deflate algorithms. -## zlib.constants +## `zlib.constants` Provides an object enumerating Zlib-related constants. -## zlib.createBrotliCompress(\[options\]) +## `zlib.createBrotliCompress([options])` @@ -636,7 +636,7 @@ added: v11.7.0 Creates and returns a new [`BrotliCompress`][] object. -## zlib.createBrotliDecompress(\[options\]) +## `zlib.createBrotliDecompress([options])` @@ -645,7 +645,7 @@ added: v11.7.0 Creates and returns a new [`BrotliDecompress`][] object. -## zlib.createDeflate(\[options\]) +## `zlib.createDeflate([options])` @@ -654,7 +654,7 @@ added: v0.5.8 Creates and returns a new [`Deflate`][] object. -## zlib.createDeflateRaw(\[options\]) +## `zlib.createDeflateRaw([options])` @@ -670,7 +670,7 @@ so Node.js restored the original behavior of upgrading a value of 8 to 9, since passing `windowBits = 9` to zlib actually results in a compressed stream that effectively uses an 8-bit window only. -## zlib.createGunzip(\[options\]) +## `zlib.createGunzip([options])` @@ -679,7 +679,7 @@ added: v0.5.8 Creates and returns a new [`Gunzip`][] object. -## zlib.createGzip(\[options\]) +## `zlib.createGzip([options])` @@ -689,7 +689,7 @@ added: v0.5.8 Creates and returns a new [`Gzip`][] object. See [example][zlib.createGzip example]. -## zlib.createInflate(\[options\]) +## `zlib.createInflate([options])` @@ -698,7 +698,7 @@ added: v0.5.8 Creates and returns a new [`Inflate`][] object. -## zlib.createInflateRaw(\[options\]) +## `zlib.createInflateRaw([options])` @@ -707,7 +707,7 @@ added: v0.5.8 Creates and returns a new [`InflateRaw`][] object. -## zlib.createUnzip(\[options\]) +## `zlib.createUnzip([options])` @@ -728,7 +728,7 @@ with `callback(error, result)`. Every method has a `*Sync` counterpart, which accept the same arguments, but without a callback. -### zlib.brotliCompress(buffer\[, options\], callback) +### `zlib.brotliCompress(buffer[, options], callback)` @@ -737,7 +737,7 @@ added: v11.7.0 * `options` {brotli options} * `callback` {Function} -### zlib.brotliCompressSync(buffer\[, options\]) +### `zlib.brotliCompressSync(buffer[, options])` @@ -747,7 +747,7 @@ added: v11.7.0 Compress a chunk of data with [`BrotliCompress`][]. -### zlib.brotliDecompress(buffer\[, options\], callback) +### `zlib.brotliDecompress(buffer[, options], callback)` @@ -756,7 +756,7 @@ added: v11.7.0 * `options` {brotli options} * `callback` {Function} -### zlib.brotliDecompressSync(buffer\[, options\]) +### `zlib.brotliDecompressSync(buffer[, options])` @@ -766,7 +766,7 @@ added: v11.7.0 Decompress a chunk of data with [`BrotliDecompress`][]. -### zlib.deflate(buffer\[, options\], callback) +### `zlib.deflate(buffer[, options], callback)`