@types/node 16.7.2 → 16.7.6

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: Thu, 26 Aug 2021 01:01:28 GMT
11
+ * Last updated: Sun, 29 Aug 2021 16:01:20 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`
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), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [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), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [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), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Minh Son Nguyen](https://github.com/nguymin4), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Surasak Chaisurin](https://github.com/Ryan-Willpower), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Jason Kwok](https://github.com/JasonHK), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), and [Linus Unnebäck](https://github.com/LinusU).
16
+ These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [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), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [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), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Minh Son Nguyen](https://github.com/nguymin4), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Surasak Chaisurin](https://github.com/Ryan-Willpower), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Jason Kwok](https://github.com/JasonHK), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), and [Linus Unnebäck](https://github.com/LinusU).
node/child_process.d.ts CHANGED
@@ -70,7 +70,7 @@ declare module 'child_process' {
70
70
  import { URL } from 'node:url';
71
71
  type Serializable = string | object | number | boolean | bigint;
72
72
  type SendHandle = net.Socket | net.Server;
73
- interface ChildProcess extends EventEmitter {
73
+ class ChildProcess extends EventEmitter {
74
74
  /**
75
75
  * A `Writable Stream` that represents the child process's `stdin`.
76
76
  *
node/fs.d.ts CHANGED
@@ -188,7 +188,7 @@ declare module 'fs' {
188
188
  /**
189
189
  * A class representing a directory stream.
190
190
  *
191
- * Created by {@link opendir}, {@link opendirSync}, or {@link romises.opendir}.
191
+ * Created by {@link opendir}, {@link opendirSync}, or {@link promises.opendir}.
192
192
  *
193
193
  * ```js
194
194
  * import { opendir } from 'fs/promises';
@@ -208,7 +208,7 @@ declare module 'fs' {
208
208
  */
209
209
  export class Dir implements AsyncIterable<Dirent> {
210
210
  /**
211
- * The read-only path of this directory as was provided to {@link opendir},{@link opendirSync}, or {@link romises.opendir}.
211
+ * The read-only path of this directory as was provided to {@link opendir}, {@link opendirSync}, or {@link promises.opendir}.
212
212
  * @since v12.12.0
213
213
  */
214
214
  readonly path: string;
node/index.d.ts CHANGED
@@ -11,7 +11,6 @@
11
11
  // Deividas Bakanas <https://github.com/DeividasBakanas>
12
12
  // Eugene Y. Q. Shen <https://github.com/eyqs>
13
13
  // Hannes Magnusson <https://github.com/Hannes-Magnusson-CK>
14
- // Hoàng Văn Khải <https://github.com/KSXGitHub>
15
14
  // Huw <https://github.com/hoo29>
16
15
  // Kelvin Jin <https://github.com/kjin>
17
16
  // Klaus Meinhardt <https://github.com/ajafff>
@@ -113,6 +112,7 @@
113
112
  /// <reference path="repl.d.ts" />
114
113
  /// <reference path="stream.d.ts" />
115
114
  /// <reference path="stream/promises.d.ts" />
115
+ /// <reference path="stream/consumers.d.ts" />
116
116
  /// <reference path="stream/web.d.ts" />
117
117
  /// <reference path="string_decoder.d.ts" />
118
118
  /// <reference path="timers.d.ts" />
node/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "16.7.2",
3
+ "version": "16.7.6",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -60,11 +60,6 @@
60
60
  "url": "https://github.com/Hannes-Magnusson-CK",
61
61
  "githubUsername": "Hannes-Magnusson-CK"
62
62
  },
63
- {
64
- "name": "Hoàng Văn Khải",
65
- "url": "https://github.com/KSXGitHub",
66
- "githubUsername": "KSXGitHub"
67
- },
68
63
  {
69
64
  "name": "Huw",
70
65
  "url": "https://github.com/hoo29",
@@ -230,6 +225,6 @@
230
225
  },
231
226
  "scripts": {},
232
227
  "dependencies": {},
233
- "typesPublisherContentHash": "e69ff975ff05f7fa6ee5e27b53994fc27f754f5397951611c387e09a08af0ce1",
228
+ "typesPublisherContentHash": "4296e98bbf5446d40cb32248836a96c827c954f3a42dd8b4591e18b7884ac707",
234
229
  "typeScriptVersion": "3.7"
235
230
  }
@@ -0,0 +1,25 @@
1
+ // Duplicates of interface in lib.dom.ts.
2
+ // Duplicated here rather than referencing lib.dom.ts because doing so causes lib.dom.ts to be loaded for "test-all"
3
+ // Which in turn causes tests to pass that shouldn't pass.
4
+ //
5
+ // This interface is not, and should not be, exported.
6
+ interface Blob {
7
+ readonly size: number;
8
+ readonly type: string;
9
+ arrayBuffer(): Promise<ArrayBuffer>;
10
+ slice(start?: number, end?: number, contentType?: string): Blob;
11
+ stream(): NodeJS.ReadableStream;
12
+ text(): Promise<string>;
13
+ }
14
+
15
+ declare module 'stream/consumers' {
16
+ import { Readable } from 'node:stream';
17
+ function buffer(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<Buffer>;
18
+ function text(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<string>;
19
+ function arrayBuffer(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<ArrayBuffer>;
20
+ function blob(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<Blob>;
21
+ function json(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<unknown>;
22
+ }
23
+ declare module 'node:stream/consumers' {
24
+ export * from 'stream/consumers';
25
+ }
node/stream.d.ts CHANGED
@@ -19,6 +19,7 @@
19
19
  declare module 'stream' {
20
20
  import { EventEmitter, Abortable } from 'node:events';
21
21
  import * as streamPromises from 'node:stream/promises';
22
+ import * as streamConsumers from 'node:stream/consumers';
22
23
  class internal extends EventEmitter {
23
24
  pipe<T extends NodeJS.WritableStream>(
24
25
  destination: T,
@@ -1169,6 +1170,7 @@ declare module 'stream' {
1169
1170
  unref(): void;
1170
1171
  }
1171
1172
  const promises: typeof streamPromises;
1173
+ const consumers: typeof streamConsumers;
1172
1174
  }
1173
1175
  export = internal;
1174
1176
  }