UNPKG

igir

Version:

🕹 A zero-setup ROM collection manager that sorts, filters, extracts or archives, patches, and reports on collections of any size on any OS.

22 lines (21 loc) • 481 B
import stream from "node:stream"; class FsReadTransform extends stream.Transform { fsReadCallback; progress = 0; constructor(fsReadCallback) { super(); this.fsReadCallback = fsReadCallback; } /** * Process the stream. */ _transform(chunk, _encoding, callback) { this.progress += chunk.length; this.fsReadCallback(this.progress); callback(null, chunk); } } export { FsReadTransform as default }; //# sourceMappingURL=fsReadTransform.js.map