* deflate(data[, options]) -> Uint8Array|Array|String * - data (Uint8Array|Array|String): input data to compress. * - options (Object): zlib deflate options. * * Compress `data` with deflate algorithm and `options`. * * Supported options are: * * - level * - windowBits * - memLevel * - st
(input, options)
| 5189 | * ``` |
| 5190 | **/ |
| 5191 | function deflate(input, options) { |
| 5192 | var deflator = new Deflate(options); |
| 5193 | |
| 5194 | deflator.push(input, true); |
| 5195 | |
| 5196 | // That will never happens, if you don't cheat with options :) |
| 5197 | if (deflator.err) { throw deflator.msg || msg[deflator.err]; } |
| 5198 | |
| 5199 | return deflator.result; |
| 5200 | } |
| 5201 | |
| 5202 | |
| 5203 | /** |
no test coverage detected