@lvcabral/zip
v1.5.0
Published
Zip backend for ZenFS (with case fold mode option)
Readme
ZenFS Zip Backend
ZenFS backend for Zip files:
Zipallows you to create a readonly file system from a zip file.- This fork adds support for the
caseFoldmode option but keeps file names in their original case and still allows case-insensitive lookups.
For more information, see the API documentation.
Please read the ZenFS core documentation!
Installation
npm install @lvcabral/zipUsage
The easiest way to get started is by looking at these examples
Zip
import { configure, fs } from '@lvcabral/zenfs';
import { Zip } from '@lvcabral/zip';
const res = await fetch('http://example.com/archive.zip');
await configure({
mounts: {
'/mnt/zip': { backend: Zip, data: await res.arrayBuffer() },
},
});
const contents = fs.readFileSync('/mnt/zip/in-archive.txt', 'utf-8');
console.log(contents);License
This project is licensed under the LGPL (v3+). See the LICENSE file for details.
