0.0.1 • Published 3 years ago

read-file-from-zip v0.0.1

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

read-file-from-zip

read utf8 data from a file inside a zip archive without unzipping.

based on a stackoverflow post.

Installation

npm i read-file-from-zip

Usage

var rfz = require('read-file-from-zip');

//sync version
var fileContentsString = rfz.readFileFromZipSync("./myArchive.zip", "zippedFile.txt");

//callback version
//rfz.readFileFromZip(zipname, filename, callback); //callback(err,data)

//get zip file list
// pass an empty filename to either of the functions above
// to get a list of entries [filename, '${sizeInBytes} bytes' || 'directory']

stonks