Questions tagged [adm-zip]

A Javascript implementation of zip for Node.js. Allows user to create or extract zip files both in memory or to/from disk.

A Javascript implementation of zip for Node.js. Allows user to create or extract zip files both in memory or to/from disk. More info can be found in the project repository.

Installation

With npm do:

$ npm install adm-zip

What is it good for?

The library allows you to:

  • decompress zip files directly to disk or in memory buffers
  • compress files and store them to disk in .zip format or in compressed buffers
  • update content of/add new/delete files from an existing .zip

Dependencies

There are no other nodeJS libraries that ADM-ZIP is dependent of

Check out the adm-zip wiki for more info.

53 questions
0
votes
1 answer

Downloading ZIP file using NodeJS and ReactJS

I am trying to download a zip file using a ReactJS client. The zip file is created at backend side (Node JS). My React client does the following: {this.state.selectedRows.length > 0 && <>
0
votes
0 answers

Read chunk with jszip

I couldn't find a way to read zip content as a chunk from HTTP response. I provide an example with JSZip library .(I'm open to other libraries if necessary ) const zip = new JSZip(); const readZipCunk = async (chunk)=>{ const ziped = await…
Bennyh961
  • 85
  • 1
  • 7
0
votes
0 answers

Download File from URL and store that file in zip using node

**Solution 1:** const zipPath = path.resolve(tempDir, 'output.zip'); const writeStream = assets.map((assets) => { fileNameArray.push(asset.fileName); return axios({ method: 'GET', responseType: 'arraybuffer', url:…
Tejaswini
  • 31
  • 3
0
votes
1 answer

Download zip file returned from server in React

The app: I'm building an app that takes screenshots with puppeteer and returns them in a zip file to a react front end. Relevant technologies: node, express, AdmZip The issue: I can get the data to the point where it triggers the automatic download,…
tganyan
  • 603
  • 3
  • 9
  • 23
0
votes
0 answers

How to create a zip file using adm-zip npm package in cypress?

I want to try to create a zip file using adm-zip in cypress but I am getting this error? It seems that cypress not recognize adm-zip function Below are my code. I hope you can help me on error stated above. import Utilities from…
J.Cruz
  • 1
0
votes
0 answers

adm-zip not adding all files

I'm noticing a strange behavior while using this library. I'm trying to compress multiple EML files, to do so I first convert them to buffers and add them to adm-zip instance using the addFile() method. Here's my code: const zip = new AdmZip(); …
osmodiar16
  • 31
  • 5
0
votes
1 answer

Create a zip file in memory and then store to AWS S3

I'm trying to create a zip file in memory (using TypeScript) and then store it in an AWS S3 bucket. The input is a plain text CSV string (data). I'm not sure what I'm doing wrong as the zip file that is created in s3 is unreadable when I download…
Guy Hagemans
  • 496
  • 1
  • 4
  • 15
0
votes
0 answers

How to see the files inside a zip without extracting the information in React Application(Javascript)?

I was trying to access a zip inside my react app without extracting the zip I need to know if a specific file is there inside a zip or not. I don't want to use any third-party application? Is it possible to get the same in JavaScript? I have tried…
Aastick
  • 91
  • 1
  • 1
  • 7
0
votes
0 answers

Unable to extract the zip file if it contains any warnings

I have a zip file, on unzipping, it extracts all the files successfully but also gives the following warning message: "There are some data after the end of the payload data". However, when I try to unzip the same file using adm-zip, I am getting…
Mike143
  • 163
  • 3
  • 14
0
votes
1 answer

AWS Lambda, node, adm-zip: bad address in system call argument

Can create and read /tmp/temp.zip with AWS Lambda but this line causes an error: var zip = new AdmZip("/tmp/temp.zip"); // https://www.npmjs.com/package/adm-zip What does the error mean? 2018-08-08T13:23:41.074Z …
Maxim Suponya
  • 1,419
  • 2
  • 20
  • 43
0
votes
1 answer

Using Node Module With React

I think, because I'm so new to Node, I'm not quite understanding how to use an NPM package with my React project running on Node. Just a quick explanation: I have a React component that uploads a zip file through Node server scripts. This part is…
Cmaxster
  • 1,035
  • 2
  • 11
  • 18
0
votes
0 answers

Extract uploaded file using adm zip

I am trying to get the list of files in a uploaded file using adm-zip. As we cant get the path of the uploaded file , iam trying to convert the zip into a Buffer and pass it to the adm-zip. But zip.getEntries(); its not giving me the list of files. …
Nayeem
  • 681
  • 15
  • 35
0
votes
0 answers

Node.js - admzip cannot compress images properly

Since a while I'm stuck at the import function of my quiz generator application, because adm-zip cannot compress images properly. Here is the errors that are returned for each images being uncompressed from the zip archive. And here is the code…
Daniel Medina
  • 33
  • 1
  • 6
0
votes
1 answer

Difference between SendToZip and C# CreateFromDirectory zipfile

I am using RestSharp to send a POST request, the POST request contains a zip file along with the following headers: request.AddParameter("username", this.username, ParameterType.GetOrPost); request.AddParameter("userid", this.userid,…
Anton James
  • 385
  • 3
  • 6
  • 18
0
votes
0 answers

`adm-zip` compression issue

I am using adm-zip to create a zip file in NodeJS successfully. The issue comes when extracting manually (as end user will do) as there appears to be a compression issue on a video file. A suggested fix might be to set adm-zip to use STORE instead…
DrogoNevets
  • 1,456
  • 3
  • 18
  • 34