jszip
jszip copied to clipboard
generateAsync not work and no error thrown on v3.10.0 and v3.10.1
It works on v3.9.1 or v3.7.1, but v3.10.x not work. I didn't try more previous versions.
It works on v3.9.1 or v3.7.1, but v3.10.x not work. I didn't try more previous versions.
I am the same as you, and I try to reduce the version to the same effect. It only appears in the production environment. The development environment is running normally
It works on v3.9.1 or v3.7.1, but v3.10.x not work. I didn't try more previous versions.
I am the same as you, and I try to reduce the version to the same effect. It only appears in the production environment. The development environment is running normally
I have the same prob, its work on dev but not prod, i guess the error caused by build.
I'm having the same issue on dev with NextJS. I get a zip but it's not at all compressed using
const zipBlob = await zip.generateAsync({
compression: "DEFLATE",
compressionOptions: {
level: 9
}
});
The exact same issue. Used in Tampermonkey '@require'. Downgrade from 3.10.1 to 3.9.1 and it works fine.
If you're using JSZip in some kind of browser sandboxed environment such as a userscript engine (e.g. Tampermonkey) JSZip v3.10+ will break because the new dependency setimmediate
breaks in that case. This is explained in Tampermonkey issue #1600 along with a workaround.
I'll post a new issue highlighting this.
Yes, it's because the setImmediate dependency, and as a solution, I used "transpileDependencies: [/[/\]node_modules/\?jszip(.*)/]", in the vue.config.js in my vue project, and it worked. If it's a react project or something, I believe you can use similar way to transpile the JSZip dependency specifically.