UNPKG

1.07 kBMarkdownView Raw
1# Installation
2> `npm install --save @types/pump`
3
4# Summary
5This package contains type definitions for pump (https://github.com/mafintosh/pump).
6
7# Details
8Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/pump.
9## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/pump/index.d.ts)
10````ts
11/// <reference types="node" />
12
13declare function pump(streams: pump.Stream[], callback?: pump.Callback): pump.Stream;
14
15// callback have to be passed as last argument
16declare function pump(...streams: Array<pump.Stream | pump.Callback>): pump.Stream;
17
18declare namespace pump {
19 type Callback = (err?: Error) => any;
20 type Stream = NodeJS.ReadableStream | NodeJS.WritableStream;
21}
22
23export = pump;
24
25````
26
27### Additional Details
28 * Last updated: Tue, 07 Nov 2023 09:09:39 GMT
29 * Dependencies: [@types/node](https://npmjs.com/package/@types/node)
30
31# Credits
32These definitions were written by [Tomek Łaziuk](https://github.com/tlaziuk), and [Jason Cordial](https://github.com/jcordial).
33
\No newline at end of file