@types/node 12.7.3 → 12.7.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
node/README.md CHANGED
@@ -8,9 +8,9 @@ This package contains type definitions for Node.js (http://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node
9
9
 
10
10
  Additional Details
11
- * Last updated: Fri, 30 Aug 2019 05:19:10 GMT
11
+ * Last updated: Tue, 24 Sep 2019 17:18:01 GMT
12
12
  * Dependencies: none
13
13
  * Global values: Buffer, NodeJS, Symbol, __dirname, __filename, clearImmediate, clearInterval, clearTimeout, console, exports, global, module, process, queueMicrotask, require, setImmediate, setInterval, setTimeout
14
14
 
15
15
  # Credits
16
- These definitions were written by Microsoft TypeScript <https://github.com/Microsoft>, DefinitelyTyped <https://github.com/DefinitelyTyped>, Alberto Schiabel <https://github.com/jkomyno>, Alexander T. <https://github.com/a-tarasyuk>, Alvis HT Tang <https://github.com/alvis>, Andrew Makarov <https://github.com/r3nya>, Benjamin Toueg <https://github.com/btoueg>, Bruno Scheufler <https://github.com/brunoscheufler>, Chigozirim C. <https://github.com/smac89>, Christian Vaagland Tellnes <https://github.com/tellnes>, David Junger <https://github.com/touffy>, Deividas Bakanas <https://github.com/DeividasBakanas>, Eugene Y. Q. Shen <https://github.com/eyqs>, Flarna <https://github.com/Flarna>, Hannes Magnusson <https://github.com/Hannes-Magnusson-CK>, Hoàng Văn Khải <https://github.com/KSXGitHub>, Huw <https://github.com/hoo29>, Kelvin Jin <https://github.com/kjin>, Klaus Meinhardt <https://github.com/ajafff>, Lishude <https://github.com/islishude>, Mariusz Wiktorczyk <https://github.com/mwiktorczyk>, Matthieu Sieben <https://github.com/matthieusieben>, Mohsen Azimi <https://github.com/mohsen1>, Nicolas Even <https://github.com/n-e>, Nicolas Voigt <https://github.com/octo-sniffle>, Parambir Singh <https://github.com/parambirs>, Sebastian Silbermann <https://github.com/eps1lon>, Simon Schick <https://github.com/SimonSchick>, Thomas den Hollander <https://github.com/ThomasdenH>, Wilco Bakker <https://github.com/WilcoBakker>, wwwy3y3 <https://github.com/wwwy3y3>, Zane Hannan AU <https://github.com/ZaneHannanAU>, Samuel Ainsworth <https://github.com/samuela>, Kyle Uehlein <https://github.com/kuehlein>, Jordi Oliveras Rovira <https://github.com/j-oliveras>, Thanik Bhongbhibhat <https://github.com/bhongy>, and Marcin Kopacz <https://github.com/chyzwar>.
16
+ These definitions were written by Microsoft TypeScript <https://github.com/Microsoft>, DefinitelyTyped <https://github.com/DefinitelyTyped>, Alberto Schiabel <https://github.com/jkomyno>, Alexander T. <https://github.com/a-tarasyuk>, Alvis HT Tang <https://github.com/alvis>, Andrew Makarov <https://github.com/r3nya>, Benjamin Toueg <https://github.com/btoueg>, Bruno Scheufler <https://github.com/brunoscheufler>, Chigozirim C. <https://github.com/smac89>, Christian Vaagland Tellnes <https://github.com/tellnes>, David Junger <https://github.com/touffy>, Deividas Bakanas <https://github.com/DeividasBakanas>, Eugene Y. Q. Shen <https://github.com/eyqs>, Flarna <https://github.com/Flarna>, Hannes Magnusson <https://github.com/Hannes-Magnusson-CK>, Hoàng Văn Khải <https://github.com/KSXGitHub>, Huw <https://github.com/hoo29>, Kelvin Jin <https://github.com/kjin>, Klaus Meinhardt <https://github.com/ajafff>, Lishude <https://github.com/islishude>, Mariusz Wiktorczyk <https://github.com/mwiktorczyk>, Matthieu Sieben <https://github.com/matthieusieben>, Mohsen Azimi <https://github.com/mohsen1>, Nicolas Even <https://github.com/n-e>, Nicolas Voigt <https://github.com/octo-sniffle>, Parambir Singh <https://github.com/parambirs>, Sebastian Silbermann <https://github.com/eps1lon>, Simon Schick <https://github.com/SimonSchick>, Thomas den Hollander <https://github.com/ThomasdenH>, Wilco Bakker <https://github.com/WilcoBakker>, wwwy3y3 <https://github.com/wwwy3y3>, Zane Hannan AU <https://github.com/ZaneHannanAU>, Samuel Ainsworth <https://github.com/samuela>, Kyle Uehlein <https://github.com/kuehlein>, Jordi Oliveras Rovira <https://github.com/j-oliveras>, Thanik Bhongbhibhat <https://github.com/bhongy>, Marcin Kopacz <https://github.com/chyzwar>, Trivikram Kamat <https://github.com/trivikr>, and Minh Son Nguyen <https://github.com/nguymin4>.
node/child_process.d.ts CHANGED
@@ -92,6 +92,24 @@ declare module "child_process" {
92
92
  ];
93
93
  }
94
94
 
95
+ // return this object when stdio option is a tuple of 3
96
+ interface ChildProcessByStdio<
97
+ I extends null | Writable,
98
+ O extends null | Readable,
99
+ E extends null | Readable,
100
+ > extends ChildProcess {
101
+ stdin: I;
102
+ stdout: O;
103
+ stderr: E;
104
+ readonly stdio: [
105
+ I,
106
+ O,
107
+ E,
108
+ Readable | Writable | null | undefined, // extra, no modification
109
+ Readable | Writable | null | undefined // extra, no modification
110
+ ];
111
+ }
112
+
95
113
  interface MessageOptions {
96
114
  keepOpen?: boolean;
97
115
  }
@@ -128,9 +146,99 @@ declare module "child_process" {
128
146
  stdio?: 'pipe' | Array<null | undefined | 'pipe'>;
129
147
  }
130
148
 
149
+ type StdioNull = 'inherit' | 'ignore' | Stream;
150
+ type StdioPipe = undefined | null | 'pipe';
151
+
152
+ interface SpawnOptionsWithStdioTuple<
153
+ Stdin extends StdioNull | StdioPipe,
154
+ Stdout extends StdioNull | StdioPipe,
155
+ Stderr extends StdioNull | StdioPipe,
156
+ > extends SpawnOptions {
157
+ stdio: [Stdin, Stdout, Stderr];
158
+ }
159
+
160
+ // overloads of spawn without 'args'
131
161
  function spawn(command: string, options?: SpawnOptionsWithoutStdio): ChildProcessWithoutNullStreams;
162
+
163
+ function spawn(
164
+ command: string,
165
+ options: SpawnOptionsWithStdioTuple<StdioPipe, StdioPipe, StdioPipe>,
166
+ ): ChildProcessByStdio<Writable, Readable, Readable>;
167
+ function spawn(
168
+ command: string,
169
+ options: SpawnOptionsWithStdioTuple<StdioPipe, StdioPipe, StdioNull>,
170
+ ): ChildProcessByStdio<Writable, Readable, null>;
171
+ function spawn(
172
+ command: string,
173
+ options: SpawnOptionsWithStdioTuple<StdioPipe, StdioNull, StdioPipe>,
174
+ ): ChildProcessByStdio<Writable, null, Readable>;
175
+ function spawn(
176
+ command: string,
177
+ options: SpawnOptionsWithStdioTuple<StdioNull, StdioPipe, StdioPipe>,
178
+ ): ChildProcessByStdio<null, Readable, Readable>;
179
+ function spawn(
180
+ command: string,
181
+ options: SpawnOptionsWithStdioTuple<StdioPipe, StdioNull, StdioNull>,
182
+ ): ChildProcessByStdio<Writable, null, null>;
183
+ function spawn(
184
+ command: string,
185
+ options: SpawnOptionsWithStdioTuple<StdioNull, StdioPipe, StdioNull>,
186
+ ): ChildProcessByStdio<null, Readable, null>;
187
+ function spawn(
188
+ command: string,
189
+ options: SpawnOptionsWithStdioTuple<StdioNull, StdioNull, StdioPipe>,
190
+ ): ChildProcessByStdio<null, null, Readable>;
191
+ function spawn(
192
+ command: string,
193
+ options: SpawnOptionsWithStdioTuple<StdioNull, StdioNull, StdioNull>,
194
+ ): ChildProcessByStdio<null, null, null>;
195
+
132
196
  function spawn(command: string, options: SpawnOptions): ChildProcess;
197
+
198
+ // overloads of spawn with 'args'
133
199
  function spawn(command: string, args?: ReadonlyArray<string>, options?: SpawnOptionsWithoutStdio): ChildProcessWithoutNullStreams;
200
+
201
+ function spawn(
202
+ command: string,
203
+ args: ReadonlyArray<string>,
204
+ options: SpawnOptionsWithStdioTuple<StdioPipe, StdioPipe, StdioPipe>,
205
+ ): ChildProcessByStdio<Writable, Readable, Readable>;
206
+ function spawn(
207
+ command: string,
208
+ args: ReadonlyArray<string>,
209
+ options: SpawnOptionsWithStdioTuple<StdioPipe, StdioPipe, StdioNull>,
210
+ ): ChildProcessByStdio<Writable, Readable, null>;
211
+ function spawn(
212
+ command: string,
213
+ args: ReadonlyArray<string>,
214
+ options: SpawnOptionsWithStdioTuple<StdioPipe, StdioNull, StdioPipe>,
215
+ ): ChildProcessByStdio<Writable, null, Readable>;
216
+ function spawn(
217
+ command: string,
218
+ args: ReadonlyArray<string>,
219
+ options: SpawnOptionsWithStdioTuple<StdioNull, StdioPipe, StdioPipe>,
220
+ ): ChildProcessByStdio<null, Readable, Readable>;
221
+ function spawn(
222
+ command: string,
223
+ args: ReadonlyArray<string>,
224
+ options: SpawnOptionsWithStdioTuple<StdioPipe, StdioNull, StdioNull>,
225
+ ): ChildProcessByStdio<Writable, null, null>;
226
+ function spawn(
227
+ command: string,
228
+ args: ReadonlyArray<string>,
229
+ options: SpawnOptionsWithStdioTuple<StdioNull, StdioPipe, StdioNull>,
230
+ ): ChildProcessByStdio<null, Readable, null>;
231
+ function spawn(
232
+ command: string,
233
+ args: ReadonlyArray<string>,
234
+ options: SpawnOptionsWithStdioTuple<StdioNull, StdioNull, StdioPipe>,
235
+ ): ChildProcessByStdio<null, null, Readable>;
236
+ function spawn(
237
+ command: string,
238
+ args: ReadonlyArray<string>,
239
+ options: SpawnOptionsWithStdioTuple<StdioNull, StdioNull, StdioNull>,
240
+ ): ChildProcessByStdio<null, null, null>;
241
+
134
242
  function spawn(command: string, args: ReadonlyArray<string>, options: SpawnOptions): ChildProcess;
135
243
 
136
244
  interface ExecOptions extends CommonOptions {
node/http.d.ts CHANGED
@@ -277,7 +277,7 @@ declare module "http" {
277
277
  rawHeaders: string[];
278
278
  trailers: { [key: string]: string | undefined };
279
279
  rawTrailers: string[];
280
- setTimeout(msecs: number, callback: () => void): this;
280
+ setTimeout(msecs: number, callback?: () => void): this;
281
281
  /**
282
282
  * Only valid for request obtained from http.Server.
283
283
  */
node/index.d.ts CHANGED
@@ -37,6 +37,8 @@
37
37
  // Jordi Oliveras Rovira <https://github.com/j-oliveras>
38
38
  // Thanik Bhongbhibhat <https://github.com/bhongy>
39
39
  // Marcin Kopacz <https://github.com/chyzwar>
40
+ // Trivikram Kamat <https://github.com/trivikr>
41
+ // Minh Son Nguyen <https://github.com/nguymin4>
40
42
  // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
41
43
 
42
44
  // NOTE: These definitions support NodeJS and TypeScript 3.2.
node/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "12.7.3",
3
+ "version": "12.7.7",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "license": "MIT",
6
6
  "contributors": [
@@ -188,6 +188,16 @@
188
188
  "name": "Marcin Kopacz",
189
189
  "url": "https://github.com/chyzwar",
190
190
  "githubUsername": "chyzwar"
191
+ },
192
+ {
193
+ "name": "Trivikram Kamat",
194
+ "url": "https://github.com/trivikr",
195
+ "githubUsername": "trivikr"
196
+ },
197
+ {
198
+ "name": "Minh Son Nguyen",
199
+ "url": "https://github.com/nguymin4",
200
+ "githubUsername": "nguymin4"
191
201
  }
192
202
  ],
193
203
  "main": "",
@@ -206,6 +216,6 @@
206
216
  },
207
217
  "scripts": {},
208
218
  "dependencies": {},
209
- "typesPublisherContentHash": "83b87121fc821ea62b5994fd27d6edd4007fcac0ad35716f9b0e488ad2855462",
219
+ "typesPublisherContentHash": "c84a19c4d732b513db6ef2569d29fbb6047ac308b4c918b12af85115ddc3a646",
210
220
  "typeScriptVersion": "2.0"
211
221
  }
node/readline.d.ts CHANGED
@@ -127,7 +127,7 @@ declare module "readline" {
127
127
 
128
128
  function createInterface(input: NodeJS.ReadableStream, output?: NodeJS.WritableStream, completer?: Completer | AsyncCompleter, terminal?: boolean): Interface;
129
129
  function createInterface(options: ReadLineOptions): Interface;
130
- function emitKeypressEvents(stream: NodeJS.ReadableStream, interface?: Interface): void;
130
+ function emitKeypressEvents(stream: NodeJS.ReadableStream, readlineInterface?: Interface): void;
131
131
 
132
132
  type Direction = -1 | 0 | 1;
133
133