Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 36.7k
Native zip support #45434
Copy link
Copy link
Open
Labels
feature requestIssues requesting new Node.js features.Issues requesting new Node.js features.never-staleIssues and PRs exempt from automated stale handling.Issues and PRs exempt from automated stale handling.zlibIssues and PRs related to the zlib module and its compression dependencies.Issues and PRs related to the zlib module and its compression dependencies.
Description
Activity
Metadata
Metadata
Assignees
Labels
feature requestIssues requesting new Node.js features.Issues requesting new Node.js features.never-staleIssues and PRs exempt from automated stale handling.Issues and PRs exempt from automated stale handling.zlibIssues and PRs related to the zlib module and its compression dependencies.Issues and PRs related to the zlib module and its compression dependencies.
Type
Projects
- StatusShow more project fieldsTriaged
What is the problem this feature will solve?
This issue is to test the water a little bit.
Node supports zlib natively, which takes care of the compression / decompression aspect of sharing files, but it doesn’t include any primitive allowing to manipulate file archives of any kind. It can be implemented in userland (and in a project of mine we’re doing this by compiling the libzip to wasm), but it’s significantly slower (both in runtime, boot time, and size).
Being able to read file archives is especially useful when coupled with the ESM loaders, since it then becomes possible to implement loading modules straight from packaged vendors - a more performant alternative to bundled packages which doesn’t require to precompile the code and allows distributing it along with non-JS files.
What is the feature you are proposing to solve the problem?
I’d like to investigate whether it’d make sense to implement a basic archive manipulation library in Node.js. This isn’t unheard of, multiple interpreters having similar capabilities, sometimes even supporting multiple formats:
The API of this basic archive library would be to define, but generally we can assume some simple requirements:
I’d be interested to explore an implementation myself.
What alternatives have you considered?
No response
@nodejs/zlib