PackageTrack

npm · #4577 most downloaded on npm

@zip.js/zip.js

2.8.60gildas-lormeau/zip.js

A JavaScript library to zip and unzip files in the browser, Deno and Node.js

Release timeline

353 releases since 2021
20212026

Releases

  1. 2.2.3723 May 2021
    Release notes
    • Fix minor issues related to ZipWriter#add and zip64 files (see https://github.com/gildas-lormeau/zip.js/commit/ba6c3faa5a26560fe4552a83deaa1772d81eb3db and https://github.com/gildas-lormeau/zip.js/commit/ba6c3faa5a26560fe4552a83deaa1772d81eb3db)
    Open source →
  2. 2.2.3619 May 2021
    Release notes
    • fix potential issue when calling ZipWriter#add with more than 4GB of data
    Open source →
  3. 2.2.3519 May 2021
    Release notes
    • improve detection of zip64 entries when calling ZipWriter#add
    Open source →
  4. 2.2.3419 May 2021
    Release notes
    • add onprogress option when calling ZipReader#getEntries and ZipWriter#close (useful when the file contains a lot of entries)
    • add lastModDate option when creating ZipWriter objects in order to to set the same last modification date to all entries
    • throw an error if attempting to create a file needing zip64 (e.g. weighting more than 4 GB) but keepOrder option is explicitly set to false
    • avoid corrupting zip files if ZipWriter#add throws an error when writing data. The error object has a property fileEntryCorrupted set to true if the entry is corrupted. When at least one entry is corrupted ZipWriter#hasCorruptedEntries is also set to true.
    Open source →
  5. 2.2.3315 May 2021
    Release notes
    • Expose terminateWorkerTimeout configuration option (see zip.configure()) to define the delay before terminating web workers automatically
    • Expose zip.terminateWorkers() to terminate idle web workers
    Open source →
  6. 2.2.3214 May 2021
    Release notes
    • Fix issue with files published on NPM (see https://github.com/gildas-lormeau/zip.js/issues/246)
    Open source →
  7. 2.2.3112 May 2021
    Release notes
    • Improve web workers usage by adding a timeout to terminate them (1000 ms by default).
    Open source →
  8. 2.2.3011 May 2021
    Release notes
    • Limit the number of simultaneous downloads (=maxWorkers) when adding entries retrieved from HTTP in a zip file (see #235)
    Open source →
  9. 2.2.2911 May 2021
    Release notes
    • fixes thrown error when the option bufferedWrite is true and data weights 2GB+ (see #239)
    • improves keepOrder option implementation
    Open source →
  10. 2.2.284 May 2021
    Release notes
    • index.d.ts: add types to addUint8Array's params (see https://github.com/gildas-lormeau/zip.js/pull/242)
    Open source →
  11. 2.2.2715 Apr 2021
    Release notes

    Expose Entry#compressionMethod (see #238)

    Open source →
  12. 2.2.265 Apr 2021
    Release notes
    • Setting the option zip64 explicitly allows to initialize reader instances as late as possible when creating a ZipWriter instance or when calling ZipWriter#add (see #235)
    • Minor speed optimization when passing data from web workers to the main process
    Open source →
  13. 2.2.2525 Mar 2021
    Release notes
    • Improve performance when compressing and decompressing files
    Open source →
  14. 2.2.2422 Mar 2021
    Release notes
    • Fix onprogress callback when calling ZipEntry#getData() (see https://github.com/gildas-lormeau/zip.js/issues/234)
    Open source →
  15. 2.2.2316 Mar 2021
    Release notes
    • Improve memory usage when computing the signature of encrypted files
    • Fix minor potential issue when reading zip64 files
    Open source →
  16. 2.2.2211 Mar 2021
    Release notes
    • Write the AES extra field in the local header each encrypted entries
    • set keepOrder to true by default to avoid generating missing zip64 entries when they are added in parallel
    Open source →
  17. 2.2.219 Mar 2021
    Release notes

    Improve performance of AES encryption/decryption (thanks @xqdoo00o)

    Open source →
  18. 2.2.205 Mar 2021
    Release notes
    • Add the option signal to ZipWriter, ZipReader, ZipWriter#add and Entry#getData which allows you to abort the compression/decompression of a file (see usage examples here and here)
    • Add the option dataDescriptor to ZipWriter#add which allows you to include or not the data descriptor record (true by default). Setting it to false will automatically set the option bufferedWrite to true.
    Open source →
  19. 2.2.194 Mar 2021

    Nothing published for this version

  20. 2.2.181 Mar 2021
    Release notes

    Add support for deflate and inflate implementation of fflate, see here for more info on how to integrate it in zip.js.

    Open source →
  21. 2.2.1723 Feb 2021
    Release notes

    Improve performances when writing multiple (large) entries in a zip file simultaneously

    Open source →
  22. 2.2.1614 Feb 2021
    Release notes
    • Add support of ZipCrypto encryption (option zipCrypto: true when creating a ZipWriter object or calling ZipWriter#add)
    • Fix issue leading to a potential invalid entry in a Zip64 file if the compressed file of the entry is larger than the original file and the total size of the zip file is > 4GB
    • Fix minor performance issue with transferable objects when using web workers
    Open source →
  23. 2.2.1514 Feb 2021

    Nothing published for this version

  24. 2.2.1411 Feb 2021
    Release notes
    • Fix issue when reading Zip64 files with appended data at the end of the file and minor issue related to the detection of Zip64 files
    • Set type to module in package.json
    • Ignore errors that could be thrown by the onprogress callback passed as option
    Open source →
  25. 2.2.1310 Feb 2021

    Nothing published for this version

  26. 2.2.127 Feb 2021
    Release notes
    • Add the new option keepOrder to the constructor ZipWriter and the method ZipWriter#add in order to keep ordered the list of files when calling ZipWriter#add multiple times in parallel
    • Support reading of zip files with invalid offsets due to data added at the start of the zip file
    • Fix issue when calling ZipWriter#add with more than one custom extra field type as option
    • Update limit to locate the End Of Central Directory Record at the end of a zip file: 64 KB => 1MB
    • Fix detection of unsupported encryption methods (e.g. ZipCrypto) and add a new constant ERR_UNSUPPORTED_ENCRYPTION
    • Expose Entry#zip64 to know if a file entry is formatted in Zip64
    • Update development dependencies
    Open source →
  27. 2.2.117 Feb 2021

    Nothing published for this version

  28. 2.2.107 Feb 2021

    Nothing published for this version

  29. 2.2.96 Feb 2021
    Release notes
    • Add zip-no-worker-deflate.min.js and zip-no-worker-inflate.min.js in the list of built files in the /dist folder
    • Add missing methods to use Uint8Array objects in the Filesystem API
    • When adding files in a zip file, auto-detect an entry is a directory if ithe name ends with a "/"
    • Minor code improvements
    Open source →
  30. 2.2.83 Feb 2021
    Release notes
    • Fix issue when an FS instance contains imported zip content and FS#export* is called with bufferedWrite set to true
    • Minor code improvements
    Open source →
  31. 2.2.731 Jan 2021
    Release notes
    • Add new options to HttpReader and HttpRangeReader (see API doc)
    • HttpReader and HttpRangeReader now rely on fetch instead of XMLHTTPRequest by default. This behavior can be changed by setting the option useXHR to true
    • HttpReader and HttpRangeReader also accept window.fetch options (when useXHR is not set to true)
    Open source →
  32. 2.2.630 Jan 2021
    Release notes
    • Fix issue when importing the code into a service worker
    Open source →
  33. 2.2.528 Jan 2021
    Release notes
    • Fix issue with the onprogress callback where sometimes the first parameter was always returning 0
    • Replace Entry#moveTo() with FS#move(). Entry#moveTo can still be used but is deprecated.
    • Add missing ZipFileEntry#replaceData64URImethod
    • FS now implements ZipDirectoryEntry
    • Add ZipEntry#getRelativeName()
    • Add the option relativePath when calling ZipDirectoryEntry.export* methods
    Open source →
  34. 2.2.427 Jan 2021
    Release notes
    • Improve the method ZipDirectoryEntry#addFileSystemEntry added in v2.2.3: it will now return the ZipEntry like other ZipDirectoryEntry#add* functions
    Open source →
  35. 2.2.327 Jan 2021
    Release notes
    • add method ZipDirectoryEntry#addFileSystemEntry to import files or directories from the filesystem into a zip
    Open source →
  36. 2.2.226 Jan 2021
    Release notes
    • Fix type definitions for typescript
    Open source →
  37. 2.2.126 Jan 2021
    Release notes
    • Fix bug if passing a comment as parameter when calling ZipWriter#close()
    • Add support of AES-128 and AES-192 encryption (AES-192 encryption is not supported on Chrome currently)
    Open source →
  38. 2.2.025 Jan 2021
    Release notes
    • This version embeds the web worker code in the library itself. The setting workerScriptsPath is now totally obsolete and you don't need to copy z-worker.js anymore in your library folder to use web workers. You can still copy and import z-worker.js with the setting workerScripts if necessary (e.g. if the CSP of the page does not allow a Blob URI as a web worker URL).
    Open source →
  39. 2.1.124 Jan 2021
    Release notes
    • zip: Fix typo in constant name zip.ERR_INVALID_PASSWORD (was previously named zip.ERR_INVALID_PASSORD)
    • zip: Add properties Entry#filenameUT8 and Entry#commentUT8 which help to determine if respectively the filename and the comment are encoded in UTF-8 in the zip file
    • zip: Fix support of UTF8 comments stored in extra fields
    • zip.fs: Fix support of options parameter when importing/exporting data
    Open source →
  40. 2.1.023 Jan 2021
    Release notes
    • Breaking change

    The path of the scripts after the first one in workerScripts will be be resolved against the URL of the first script instead of the base URI of the page. For example with the version 2.0.x, if you had in your code something similar to this:

    zip.configure({
      workerScripts: {
        inflate: ["./lib/z-worker-pako.js", "./lib/pako_inflate.min.js"]
      }
    });
    

    You must replace it with:

    zip.configure({
      workerScripts: {
        inflate: ["./lib/z-worker-pako.js", "./pako_inflate.min.js"] // pako_inflate.min.js is in the same folder than z-worker-pako.js
      }
    });
    

    • Fix a regression introduced in the version 2.0.13 when decoding UTF-8 filenames/comments found in the corresponding Extra Field
    • Add ZipFileEntry#replaceBlob and ZipFileEntry#replaceText methods in the FileSystem API
    • ZipWriter#add returns a Promise with an Entry object as resolved value instead of undefined
    Open source →
  41. 2.0.1222 Jan 2021
    Release notes
    • Include deflate.js and inflate.js as modules in zip.js and z-worker.js. You don't need to include deflate.js and inflate.js anymore in your page and your /lib folder. They have also been removed from the /dist folder.
    • Minor code improvements
    Open source →
  42. 2.0.1122 Jan 2021
    Release notes
    • Fix potential race condition bug when calling multiple times ZipWriter.add in parallel with the same instance of options object (fix wasn't ok in v2.0.9)
    • Add options parameter to ZipReader.getEntries in order to use a user-provided encoding for filenames and comments
    Open source →
  43. 2.0.1022 Jan 2021

    Nothing published for this version

  44. 2.0.922 Jan 2021
    Release notes
    • Fix potential race condition bug when calling ZipWriter.add in parallel with the same instance of options object
    • Add validation of the last modification date given as an option when calling ZipWriter.add
    Open source →
  45. 2.0.822 Jan 2021
    Release notes
    • Add useWebWorkers option when calling ZipReader, ZipWriter constructors and ZipReader#getData, ZipWriter#add to force enabling/disabling the usage of web workers
    • Fix handling of the option version
    • Remove usage of unescape and encodeURIComponent in the code (replaced with TextEncoder)
    • Add FS API in the types declaration file
    • Various improvements in the code
    Open source →
  46. 2.0.721 Jan 2021

    Nothing published for this version

  47. 2.0.621 Jan 2021

    Nothing published for this version

  48. 2.0.520 Jan 2021

    Nothing published for this version

  49. 2.0.420 Jan 2021

    Nothing published for this version

  50. 2.0.319 Jan 2021

    Nothing published for this version

  51. 2.0.219 Jan 2021

    Nothing published for this version

  52. 2.0.119 Jan 2021

    Nothing published for this version

  53. 2.0.019 Jan 2021

    Nothing published for this version