jszip

Create, read and edit .zip files with JavaScript http://stuartk.com/jszip

(MIT OR GPL-3.0-or-later) 38 个版本
安装
npm install jszip
yarn add jszip
pnpm add jszip
bun add jszip
README

JSZip

A library for creating, reading and editing .zip files with JavaScript, with a lovely and simple API.

See https://stuk.github.io/jszip for all the documentation.

const zip = new JSZip();

zip.file("Hello.txt", "Hello World\n");

const img = zip.folder("images");
img.file("smile.gif", imgData, {base64: true});

zip.generateAsync({type:"blob"}).then(function(content) {
    // see FileSaver.js
    saveAs(content, "example.zip");
});

/*
Results in a zip containing
Hello.txt
images/
    smile.gif
*/

License

JSZip is dual-licensed. You may use it under the MIT license or the GPLv3 license. See LICENSE.markdown.

版本列表
3.10.1 2022-08-02
3.10.0 2022-05-20
3.9.1 2022-04-06
3.9.0 2022-04-05
3.8.0 2022-03-30
3.7.1 2021-08-05
3.7.0 2021-07-23
3.6.0-0 2021-02-09
3.6.0 2021-02-10
3.5.0 2020-06-14
3.4.0 2020-04-19
3.3.0 2020-04-01
3.2.2 2019-07-03
3.2.1 2019-03-22
3.2.0 2019-02-21
3.1.5 2017-11-09
3.1.4 2017-08-24
3.1.3 2016-10-06
3.1.2 2016-08-23
3.1.1 2016-08-08
3.1.0 2016-08-03
3.0.0 2016-04-13
2.7.0 2022-08-02
2.6.1 2016-07-28
2.6.0 2016-03-23
2.5.0 2015-03-12
2.4.0 2014-07-25
2.3.0 2014-06-18
2.2.2 2014-05-01
2.2.1 2014-04-24
2.2.0 2014-02-26
2.1.1 2014-02-13
2.1.0 2014-02-06
2.0.0 2014-02-06
0.2.1 2013-09-30
0.2.0 2013-09-25
0.1.1 2013-09-11
0.1.0 2013-09-11