zip.js

JavaScript library to zip and unzip files supporting multi-core compression, compression streams, zip64, split files and encryption.

BSD-3-CLAUSE License

Downloads
3.4M
Stars
3.4K
Committers
28

Bot releases are hidden (Show)

zip.js -

Published by gildas-lormeau about 2 years ago

Added SplitZipWriter class which can be used in order to create split zip files with ZipWriter (cf. test here)

zip.js -

Published by gildas-lormeau about 2 years ago

  • Fixed potential issue related to zip64 format auto-detection when adding concurrently ReadableStream and Reader instances simultaneously in a zip file weighting more than 4GB
  • Fixed unnecessary data retrieval (approx. 30 bytes) when extracting a zip entry
  • Added rollup-es5.config.js and rollup-es5.config.dev.js scripts in order to build zip.js for older engines (see instructions in the header comment)
zip.js -

Published by gildas-lormeau about 2 years ago

Improved implementation of the fix from the previous version (2.6.30) for the potential race data condition in Firefox when reading zip files

zip.js -

Published by gildas-lormeau about 2 years ago

  • Added support of split zip files when using ZipReader via the SplitZipReader class (see example here)
  • Fixed potential data race issue in Firefox when unzipping files with the option transferStreams set to true (introduced in version 2.6.24) that could lead to truncated files
  • Make sure build scripts can run in environments where globalThis is undefined (see https://github.com/gildas-lormeau/zip.js/issues/254#issuecomment-1254145896)
zip.js -

Published by gildas-lormeau about 2 years ago

Added support of CommonJS modules (see "Installation" here: https://gildas-lormeau.github.io/zip.js/)

zip.js -

Published by gildas-lormeau about 2 years ago

  • Added new options when calling configure in order to pass custom CompressionStream and DecompressionStream implementations
  • Reduced the size of built files (~ 2%)
  • Fixed issue when getting navigator.hardwareConcurrency on Deno Deploy
zip.js -

Published by gildas-lormeau about 2 years ago

  • Improve support of streams. You can now use directly ReadableStream or WritableStream instances instead of Reader or Writer instances respectively without needing to wrap them into objects.
  • zip.js now creates Zip64 entries automatically when calling ZipWriter#add() and passing ReadableStream instances. If you're sure that resulting the zip file won't exceed 4GB, you can pass the option zip64: false explicitly to disable this behavior.
zip.js -

Published by gildas-lormeau about 2 years ago

Fixed TypeScript compilation issue due to a syntax error in the index.d.ts file (see https://github.com/gildas-lormeau/zip.js/pull/366)

zip.js -

Published by gildas-lormeau about 2 years ago

Added a new option when creating a ZipReader instance or when calling ZipReader#getData(). This option is named transferStreams and is set to true by default.

  • When set to false, zip.js should work as before. zip.js will read/write chunks of data when decompressing data by exchanging messages between the main thread and web workers.
  • When set to true, zip.js will try to transfer the ReadableStream and the WritableStream instances used when decompressing data to the web workers. Thus, data is transferred natively between the main thread and the web workers.
    If the environment does not allow streams to be transferred to web workers, zip.js automatically falls back to the implementation corresponding to transferStreams set to false.

Note that transferable streams are not supported in Deno currently.

zip.js - v2.6.23

Published by gildas-lormeau about 2 years ago

  • Fixed BlobWriter mime type not present (see #360)
zip.js -

Published by gildas-lormeau about 2 years ago

Improved automatic detection of entries that should use Zip64 data when compressing entries in parallel (i.e. if the zip file is going to weight more than 4GB)

zip.js -

Published by gildas-lormeau about 2 years ago

zip.js -

Published by gildas-lormeau about 2 years ago

  • Added the missing method FS#importUint8Array
  • Fixed a bug where zip.js would decide to use a buffer to write compressed data sequentially whereas it's not needed
  • Improved implementation of compression abort
zip.js -

Published by gildas-lormeau about 2 years ago

Improve the implementation of BlobWriter by using a TransformStream instance under the hood

zip.js - v2.6.16

Published by gildas-lormeau about 2 years ago

What's Changed

Full Changelog: https://github.com/gildas-lormeau/zip.js/compare/v2.6.15...v2.6.16

zip.js -

Published by gildas-lormeau about 2 years ago

  • Fixed potential data corruption issue when aborting the compression of (unbuffered) data in a zip file
  • Added basic example (i.e. not based on Streams) in the README file
  • Updated and fixed API doc on deno.land
zip.js -

Published by gildas-lormeau about 2 years ago

  • Improve the performance of Uint8ArrayWriter when calling Entry#getData()
zip.js -

Published by gildas-lormeau about 2 years ago

Make sure file names encoded in CP437 in zip files are properly decoded when the source code of zip.js is not parsed in UTF-8 (see #352)

zip.js -

Published by gildas-lormeau about 2 years ago

  • No changes in the code of the library
  • Moved test launcher and build scripts in the package.json file
  • Improved UX of the test runner for Node.js
zip.js -

Published by gildas-lormeau about 2 years ago

  • Fixed a bug where adding 2 entries with the same filename concurrently with ZipWriter#add() did not necessarily trigger an exception (the first entry was overridden by the second one).
  • Added some examples in the API documentation.