Files
factorio-clusterio/packages/lib/package.json
T
Cooldude2606andClaude Opus 5.5 59fa8403de Keep yauzl and yazl types out of lib's published declarations (#1235)
* Keep yauzl and yazl types out of lib's published declarations

ZipArchive exposed yauzl.ZipFile and yauzl.Entry in its public members
and zipOutputStream took a yazl.ZipFile, so @types/yauzl and @types/yazl
had to be runtime dependencies of @clusterio/lib. They pull in
@types/node and undici-types, about 2.7 MB in every server install.

Entries are now typed with a local ZipEntry interface, the yauzl
ZipFile is private, and zipOutputStream takes any object with an
outputStream and an error event. ZipWriter.addEntry reads the
compressed bytes through the new ZipArchive.openRawStream. Both type
packages move to devDependencies.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Explain why ZipEntry is a local type

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-20 20:54:56 +00:00

76 lines
1.7 KiB
JSON

{
"name": "@clusterio/lib",
"version": "2.1.1",
"description": "Shared library for Clusterio",
"homepage": "https://github.com/clusterio/clusterio#readme",
"author": "Hornwitser <github@hornwitser.no>",
"license": "MIT",
"keywords": [
"clusterio",
"factorio"
],
"repository": {
"type": "git",
"url": "https://github.com/clusterio/clusterio"
},
"bugs": {
"url": "https://github.com/clusterio/clusterio/issues"
},
"publishConfig": {
"access": "public"
},
"type": "module",
"imports": {
"#WebSocket": {
"node": {
"types": "./src/link/WebSocket.node.ts",
"default": "./dist/node/src/link/WebSocket.node.js"
},
"import": "./src/link/WebSocket.browser.ts"
},
"#is_deep_strict_equal": {
"node": {
"types": "./src/is_deep_strict_equal.node.ts",
"default": "./dist/node/src/is_deep_strict_equal.node.js"
},
"import": "./src/is_deep_strict_equal.browser.ts"
}
},
"browser": "browser.ts",
"main": "dist/node/index.js",
"scripts": {
"prepare": "tsc --build && pnpm run compile_validator",
"compile_validator": "node scripts/compile_validator.js"
},
"engines": {
"node": "^22.18.0 || >=24.2.0"
},
"dependencies": {
"@sinclair/typebox": "catalog:",
"ajv": "^8.20.0",
"fast-deep-equal": "^3.1.3",
"set-blocking": "catalog:",
"triple-beam": "^1.4.1",
"winston": "catalog:",
"winston-transport": "catalog:",
"ws": "catalog:",
"yargs": "catalog:",
"yauzl": "catalog:",
"yazl": "catalog:"
},
"devDependencies": {
"@types/node": "catalog:",
"@types/set-blocking": "catalog:",
"@types/triple-beam": "^1.3.5",
"@types/ws": "catalog:",
"@types/yargs": "catalog:",
"@types/yauzl": "catalog:",
"@types/yazl": "catalog:",
"typescript": "catalog:"
}
}