EvanOxfeld / node-unzip

node.js cross-platform unzip using streams
MIT License
613 stars 343 forks source link

Pipe signature on Entry #113

Open CarstenLeue opened 6 years ago

CarstenLeue commented 6 years ago

The typescript signature for Entry is:

export interface Entry {
    path: string;
    type: 'Directory' | 'File';
    size: number;
    pipe: (stream: NodeJS.WritableStream) => void;
    autodrain: () => void;
}

I think that it should be

export interface Entry {
    path: string;
    type: 'Directory' | 'File';
    size: number;
    pipe: <T extends NodeJS.WritableStream>(stream: T) => T;
    autodrain: () => void;
}