@types/node 9.6.57 → 9.6.61
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 v9.6/README.md +2 -2
- node v9.6/base.d.ts +38 -39
- node v9.6/index.d.ts +7 -25
- node v9.6/package.json +3 -10
- node v9.6/ts3.2/index.d.ts +0 -23
node v9.6/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/v9.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated:
|
|
11
|
+
* Last updated: Wed, 28 Oct 2020 18:55:51 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
|
-
* Global values: `Buffer`, `NodeJS`, `SlowBuffer`, `
|
|
13
|
+
* Global values: `Buffer`, `NodeJS`, `SlowBuffer`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `require`, `setImmediate`, `setInterval`, `setTimeout`
|
|
14
14
|
|
|
15
15
|
# Credits
|
|
16
16
|
These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Parambir Singh](https://github.com/parambirs), [Wilco Bakker](https://github.com/WilcoBakker), [Chigozirim C.](https://github.com/smac89), [Flarna](https://github.com/Flarna), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [wwwy3y3](https://github.com/wwwy3y3), [Deividas Bakanas](https://github.com/DeividasBakanas), [Kelvin Jin](https://github.com/kjin), [Alvis HT Tang](https://github.com/alvis), [Sebastian Silbermann](https://github.com/eps1lon), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Alberto Schiabel](https://github.com/jkomyno), [Klaus Meinhardt](https://github.com/ajafff), [Huw](https://github.com/hoo29), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Bruno Scheufler](https://github.com/brunoscheufler), [Mohsen Azimi](https://github.com/mohsen1), [Hoàng Văn Khải](https://github.com/KSXGitHub), [Alexander T.](https://github.com/a-tarasyuk), [Lishude](https://github.com/islishude), [Andrew Makarov](https://github.com/r3nya), [Eugene Y. Q. Shen](https://github.com/eyqs), [Jordi Oliveras Rovira](https://github.com/j-oliveras), and [Thanik Bhongbhibhat](https://github.com/bhongy).
|
node v9.6/base.d.ts
CHANGED
|
@@ -102,7 +102,7 @@ interface Console {
|
|
|
102
102
|
* This method does not display anything unless used in the inspector.
|
|
103
103
|
* Prints to `stdout` the array `array` formatted as a table.
|
|
104
104
|
*/
|
|
105
|
-
table(tabularData: any, properties?: string
|
|
105
|
+
table(tabularData: any, properties?: ReadonlyArray<string>): void;
|
|
106
106
|
/**
|
|
107
107
|
* This method does not display anything unless used in the inspector.
|
|
108
108
|
* Adds an event with the label `label` to the Timeline panel of the inspector.
|
|
@@ -180,7 +180,6 @@ declare function clearImmediate(immediateId: any): void;
|
|
|
180
180
|
|
|
181
181
|
// TODO: change to `type NodeRequireFunction = (id: string) => any;` in next mayor version.
|
|
182
182
|
interface NodeRequireFunction {
|
|
183
|
-
/* tslint:disable-next-line:callable-types */
|
|
184
183
|
(id: string): any;
|
|
185
184
|
}
|
|
186
185
|
|
|
@@ -224,11 +223,11 @@ declare var SlowBuffer: {
|
|
|
224
223
|
new(str: string, encoding?: string): Buffer;
|
|
225
224
|
new(size: number): Buffer;
|
|
226
225
|
new(size: Uint8Array): Buffer;
|
|
227
|
-
new(array: any
|
|
226
|
+
new(array: ReadonlyArray<any>): Buffer;
|
|
228
227
|
prototype: Buffer;
|
|
229
228
|
isBuffer(obj: any): boolean;
|
|
230
229
|
byteLength(string: string, encoding?: string): number;
|
|
231
|
-
concat(list: Buffer
|
|
230
|
+
concat(list: ReadonlyArray<Buffer>, totalLength?: number): Buffer;
|
|
232
231
|
};
|
|
233
232
|
|
|
234
233
|
// Buffer class
|
|
@@ -328,7 +327,7 @@ declare var Buffer: {
|
|
|
328
327
|
*
|
|
329
328
|
* @param array The octets to store.
|
|
330
329
|
*/
|
|
331
|
-
new(array: any
|
|
330
|
+
new(array: ReadonlyArray<any>): Buffer;
|
|
332
331
|
/**
|
|
333
332
|
* Copies the passed {buffer} data onto a new {Buffer} instance.
|
|
334
333
|
*
|
|
@@ -349,7 +348,7 @@ declare var Buffer: {
|
|
|
349
348
|
* Creates a new Buffer using the passed {data}
|
|
350
349
|
* @param data data to create a new Buffer
|
|
351
350
|
*/
|
|
352
|
-
from(data: any
|
|
351
|
+
from(data: ReadonlyArray<any> | string | Buffer | ArrayBuffer /*| TypedArray*/): Buffer;
|
|
353
352
|
/**
|
|
354
353
|
* Creates a new Buffer containing the given JavaScript string {str}.
|
|
355
354
|
* If provided, the {encoding} parameter identifies the character encoding.
|
|
@@ -388,7 +387,7 @@ declare var Buffer: {
|
|
|
388
387
|
* @param totalLength Total length of the buffers when concatenated.
|
|
389
388
|
* If totalLength is not provided, it is read from the buffers in the list. However, this adds an additional loop to the function, so it is faster to provide the length explicitly.
|
|
390
389
|
*/
|
|
391
|
-
concat(list: Uint8Array
|
|
390
|
+
concat(list: ReadonlyArray<Uint8Array>, totalLength?: number): Buffer;
|
|
392
391
|
/**
|
|
393
392
|
* The same as buf1.compare(buf2).
|
|
394
393
|
*/
|
|
@@ -694,7 +693,7 @@ declare namespace NodeJS {
|
|
|
694
693
|
getegid(): number;
|
|
695
694
|
setegid(id: number | string): void;
|
|
696
695
|
getgroups(): number[];
|
|
697
|
-
setgroups(groups:
|
|
696
|
+
setgroups(groups: ReadonlyArray<string | number>): void;
|
|
698
697
|
setUncaughtExceptionCaptureCallback(cb: ((err: Error) => void) | null): void;
|
|
699
698
|
hasUncaughtExceptionCaptureCallback(): boolean;
|
|
700
699
|
version: string;
|
|
@@ -1105,13 +1104,13 @@ declare module "http" {
|
|
|
1105
1104
|
|
|
1106
1105
|
setTimeout(msecs: number, callback?: () => void): this;
|
|
1107
1106
|
destroy(error: Error): void;
|
|
1108
|
-
setHeader(name: string, value: number | string | string
|
|
1107
|
+
setHeader(name: string, value: number | string | ReadonlyArray<string>): void;
|
|
1109
1108
|
getHeader(name: string): number | string | string[] | undefined;
|
|
1110
1109
|
getHeaders(): OutgoingHttpHeaders;
|
|
1111
1110
|
getHeaderNames(): string[];
|
|
1112
1111
|
hasHeader(name: string): boolean;
|
|
1113
1112
|
removeHeader(name: string): void;
|
|
1114
|
-
addTrailers(headers: OutgoingHttpHeaders |
|
|
1113
|
+
addTrailers(headers: OutgoingHttpHeaders | ReadonlyArray<[string, string]>): void;
|
|
1115
1114
|
flushHeaders(): void;
|
|
1116
1115
|
}
|
|
1117
1116
|
|
|
@@ -1853,7 +1852,7 @@ declare module "punycode" {
|
|
|
1853
1852
|
export var ucs2: ucs2;
|
|
1854
1853
|
interface ucs2 {
|
|
1855
1854
|
decode(string: string): number[];
|
|
1856
|
-
encode(codePoints: number
|
|
1855
|
+
encode(codePoints: ReadonlyArray<number>): string;
|
|
1857
1856
|
}
|
|
1858
1857
|
export var version: any;
|
|
1859
1858
|
}
|
|
@@ -2572,48 +2571,48 @@ declare module "child_process" {
|
|
|
2572
2571
|
|
|
2573
2572
|
export function execFile(file: string): ChildProcess;
|
|
2574
2573
|
export function execFile(file: string, options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null): ChildProcess;
|
|
2575
|
-
export function execFile(file: string, args: string
|
|
2576
|
-
export function execFile(file: string, args: string
|
|
2574
|
+
export function execFile(file: string, args: ReadonlyArray<string> | undefined | null): ChildProcess;
|
|
2575
|
+
export function execFile(file: string, args: ReadonlyArray<string> | undefined | null, options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null): ChildProcess;
|
|
2577
2576
|
|
|
2578
2577
|
// no `options` definitely means stdout/stderr are `string`.
|
|
2579
2578
|
export function execFile(file: string, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
|
|
2580
|
-
export function execFile(file: string, args: string
|
|
2579
|
+
export function execFile(file: string, args: ReadonlyArray<string> | undefined | null, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
|
|
2581
2580
|
|
|
2582
2581
|
// `options` with `"buffer"` or `null` for `encoding` means stdout/stderr are definitely `Buffer`.
|
|
2583
2582
|
export function execFile(file: string, options: ExecFileOptionsWithBufferEncoding, callback: (error: Error | null, stdout: Buffer, stderr: Buffer) => void): ChildProcess;
|
|
2584
|
-
export function execFile(file: string, args: string
|
|
2583
|
+
export function execFile(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptionsWithBufferEncoding, callback: (error: Error | null, stdout: Buffer, stderr: Buffer) => void): ChildProcess;
|
|
2585
2584
|
|
|
2586
2585
|
// `options` with well known `encoding` means stdout/stderr are definitely `string`.
|
|
2587
2586
|
export function execFile(file: string, options: ExecFileOptionsWithStringEncoding, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
|
|
2588
|
-
export function execFile(file: string, args: string
|
|
2587
|
+
export function execFile(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptionsWithStringEncoding, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
|
|
2589
2588
|
|
|
2590
2589
|
// `options` with an `encoding` whose type is `string` means stdout/stderr could either be `Buffer` or `string`.
|
|
2591
2590
|
// There is no guarantee the `encoding` is unknown as `string` is a superset of `BufferEncoding`.
|
|
2592
2591
|
export function execFile(file: string, options: ExecFileOptionsWithOtherEncoding, callback: (error: Error | null, stdout: string | Buffer, stderr: string | Buffer) => void): ChildProcess;
|
|
2593
|
-
export function execFile(file: string, args: string
|
|
2592
|
+
export function execFile(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptionsWithOtherEncoding, callback: (error: Error | null, stdout: string | Buffer, stderr: string | Buffer) => void): ChildProcess;
|
|
2594
2593
|
|
|
2595
2594
|
// `options` without an `encoding` means stdout/stderr are definitely `string`.
|
|
2596
2595
|
export function execFile(file: string, options: ExecFileOptions, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
|
|
2597
|
-
export function execFile(file: string, args: string
|
|
2596
|
+
export function execFile(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptions, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
|
|
2598
2597
|
|
|
2599
2598
|
// fallback if nothing else matches. Worst case is always `string | Buffer`.
|
|
2600
2599
|
export function execFile(file: string, options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null, callback: ((error: Error | null, stdout: string | Buffer, stderr: string | Buffer) => void) | undefined | null): ChildProcess;
|
|
2601
|
-
export function execFile(file: string, args: string
|
|
2600
|
+
export function execFile(file: string, args: ReadonlyArray<string> | undefined | null, options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null, callback: ((error: Error | null, stdout: string | Buffer, stderr: string | Buffer) => void) | undefined | null): ChildProcess;
|
|
2602
2601
|
|
|
2603
2602
|
// NOTE: This namespace provides design-time support for util.promisify. Exported members do not exist at runtime.
|
|
2604
2603
|
export namespace execFile {
|
|
2605
2604
|
export function __promisify__(file: string): Promise<{ stdout: string, stderr: string }>;
|
|
2606
|
-
export function __promisify__(file: string, args: string
|
|
2605
|
+
export function __promisify__(file: string, args: ReadonlyArray<string> | undefined | null): Promise<{ stdout: string, stderr: string }>;
|
|
2607
2606
|
export function __promisify__(file: string, options: ExecFileOptionsWithBufferEncoding): Promise<{ stdout: Buffer, stderr: Buffer }>;
|
|
2608
|
-
export function __promisify__(file: string, args: string
|
|
2607
|
+
export function __promisify__(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptionsWithBufferEncoding): Promise<{ stdout: Buffer, stderr: Buffer }>;
|
|
2609
2608
|
export function __promisify__(file: string, options: ExecFileOptionsWithStringEncoding): Promise<{ stdout: string, stderr: string }>;
|
|
2610
|
-
export function __promisify__(file: string, args: string
|
|
2609
|
+
export function __promisify__(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptionsWithStringEncoding): Promise<{ stdout: string, stderr: string }>;
|
|
2611
2610
|
export function __promisify__(file: string, options: ExecFileOptionsWithOtherEncoding): Promise<{ stdout: string | Buffer, stderr: string | Buffer }>;
|
|
2612
|
-
export function __promisify__(file: string, args: string
|
|
2611
|
+
export function __promisify__(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptionsWithOtherEncoding): Promise<{ stdout: string | Buffer, stderr: string | Buffer }>;
|
|
2613
2612
|
export function __promisify__(file: string, options: ExecFileOptions): Promise<{ stdout: string, stderr: string }>;
|
|
2614
|
-
export function __promisify__(file: string, args: string
|
|
2613
|
+
export function __promisify__(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptions): Promise<{ stdout: string, stderr: string }>;
|
|
2615
2614
|
export function __promisify__(file: string, options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null): Promise<{ stdout: string | Buffer, stderr: string | Buffer }>;
|
|
2616
|
-
export function __promisify__(file: string, args: string
|
|
2615
|
+
export function __promisify__(file: string, args: ReadonlyArray<string> | undefined | null, options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null): Promise<{ stdout: string | Buffer, stderr: string | Buffer }>;
|
|
2617
2616
|
}
|
|
2618
2617
|
|
|
2619
2618
|
export interface ForkOptions {
|
|
@@ -2629,7 +2628,7 @@ declare module "child_process" {
|
|
|
2629
2628
|
windowsVerbatimArguments?: boolean;
|
|
2630
2629
|
}
|
|
2631
2630
|
export function fork(modulePath: string, options?: ForkOptions): ChildProcess;
|
|
2632
|
-
export function fork(modulePath: string, args?: string
|
|
2631
|
+
export function fork(modulePath: string, args?: ReadonlyArray<string>, options?: ForkOptions): ChildProcess;
|
|
2633
2632
|
|
|
2634
2633
|
export interface SpawnSyncOptions {
|
|
2635
2634
|
cwd?: string;
|
|
@@ -2665,9 +2664,9 @@ declare module "child_process" {
|
|
|
2665
2664
|
export function spawnSync(command: string, options?: SpawnSyncOptionsWithStringEncoding): SpawnSyncReturns<string>;
|
|
2666
2665
|
export function spawnSync(command: string, options?: SpawnSyncOptionsWithBufferEncoding): SpawnSyncReturns<Buffer>;
|
|
2667
2666
|
export function spawnSync(command: string, options?: SpawnSyncOptions): SpawnSyncReturns<Buffer>;
|
|
2668
|
-
export function spawnSync(command: string, args?: string
|
|
2669
|
-
export function spawnSync(command: string, args?: string
|
|
2670
|
-
export function spawnSync(command: string, args?: string
|
|
2667
|
+
export function spawnSync(command: string, args?: ReadonlyArray<string>, options?: SpawnSyncOptionsWithStringEncoding): SpawnSyncReturns<string>;
|
|
2668
|
+
export function spawnSync(command: string, args?: ReadonlyArray<string>, options?: SpawnSyncOptionsWithBufferEncoding): SpawnSyncReturns<Buffer>;
|
|
2669
|
+
export function spawnSync(command: string, args?: ReadonlyArray<string>, options?: SpawnSyncOptions): SpawnSyncReturns<Buffer>;
|
|
2671
2670
|
|
|
2672
2671
|
export interface ExecSyncOptions {
|
|
2673
2672
|
cwd?: string;
|
|
@@ -2717,9 +2716,9 @@ declare module "child_process" {
|
|
|
2717
2716
|
export function execFileSync(command: string, options?: ExecFileSyncOptionsWithStringEncoding): string;
|
|
2718
2717
|
export function execFileSync(command: string, options?: ExecFileSyncOptionsWithBufferEncoding): Buffer;
|
|
2719
2718
|
export function execFileSync(command: string, options?: ExecFileSyncOptions): Buffer;
|
|
2720
|
-
export function execFileSync(command: string, args?: string
|
|
2721
|
-
export function execFileSync(command: string, args?: string
|
|
2722
|
-
export function execFileSync(command: string, args?: string
|
|
2719
|
+
export function execFileSync(command: string, args?: ReadonlyArray<string>, options?: ExecFileSyncOptionsWithStringEncoding): string;
|
|
2720
|
+
export function execFileSync(command: string, args?: ReadonlyArray<string>, options?: ExecFileSyncOptionsWithBufferEncoding): Buffer;
|
|
2721
|
+
export function execFileSync(command: string, args?: ReadonlyArray<string>, options?: ExecFileSyncOptions): Buffer;
|
|
2723
2722
|
}
|
|
2724
2723
|
|
|
2725
2724
|
declare module "url" {
|
|
@@ -2778,7 +2777,7 @@ declare module "url" {
|
|
|
2778
2777
|
}
|
|
2779
2778
|
|
|
2780
2779
|
export class URLSearchParams implements Iterable<[string, string]> {
|
|
2781
|
-
constructor(init?: URLSearchParams | string | { [key: string]: string | string
|
|
2780
|
+
constructor(init?: URLSearchParams | string | { [key: string]: string | ReadonlyArray<string> | undefined } | Iterable<[string, string]> | ReadonlyArray<[string, string]>);
|
|
2782
2781
|
append(name: string, value: string): void;
|
|
2783
2782
|
delete(name: string): void;
|
|
2784
2783
|
entries(): IterableIterator<[string, string]>;
|
|
@@ -3049,7 +3048,7 @@ declare module "dns" {
|
|
|
3049
3048
|
}
|
|
3050
3049
|
|
|
3051
3050
|
export function reverse(ip: string, callback: (err: NodeJS.ErrnoException, hostnames: string[]) => void): void;
|
|
3052
|
-
export function setServers(servers: string
|
|
3051
|
+
export function setServers(servers: ReadonlyArray<string>): void;
|
|
3053
3052
|
export function getServers(): string[];
|
|
3054
3053
|
|
|
3055
3054
|
// Error codes
|
|
@@ -3380,7 +3379,7 @@ declare module "dgram" {
|
|
|
3380
3379
|
export function createSocket(options: SocketOptions, callback?: (msg: Buffer, rinfo: RemoteInfo) => void): Socket;
|
|
3381
3380
|
|
|
3382
3381
|
export class Socket extends events.EventEmitter {
|
|
3383
|
-
send(msg: Buffer | string | Uint8Array | any
|
|
3382
|
+
send(msg: Buffer | string | Uint8Array | ReadonlyArray<any>, port: number, address?: string, callback?: (error: Error | null, bytes: number) => void): void;
|
|
3384
3383
|
send(msg: Buffer | string | Uint8Array, offset: number, length: number, port: number, address?: string, callback?: (error: Error | null, bytes: number) => void): void;
|
|
3385
3384
|
bind(port?: number, address?: string, callback?: () => void): void;
|
|
3386
3385
|
bind(port?: number, callback?: () => void): void;
|
|
@@ -5371,7 +5370,7 @@ declare module "tls" {
|
|
|
5371
5370
|
* An array of strings or a Buffer naming possible NPN protocols.
|
|
5372
5371
|
* (Protocols should be ordered by their priority.)
|
|
5373
5372
|
*/
|
|
5374
|
-
NPNProtocols?: string
|
|
5373
|
+
NPNProtocols?: ReadonlyArray<string> | ReadonlyArray<Buffer> | ReadonlyArray<Uint8Array> | Buffer | Uint8Array,
|
|
5375
5374
|
/**
|
|
5376
5375
|
* An array of strings or a Buffer naming possible ALPN protocols.
|
|
5377
5376
|
* (Protocols should be ordered by their priority.) When the server
|
|
@@ -5379,7 +5378,7 @@ declare module "tls" {
|
|
|
5379
5378
|
* precedence over NPN and the server does not send an NPN extension
|
|
5380
5379
|
* to the client.
|
|
5381
5380
|
*/
|
|
5382
|
-
ALPNProtocols?: string
|
|
5381
|
+
ALPNProtocols?: ReadonlyArray<string> | ReadonlyArray<Buffer> | ReadonlyArray<Uint8Array> | Buffer | Uint8Array,
|
|
5383
5382
|
/**
|
|
5384
5383
|
* SNICallback(servername, cb) <Function> A function that will be
|
|
5385
5384
|
* called if the client supports SNI TLS extension. Two arguments
|
|
@@ -7272,7 +7271,7 @@ declare module "http2" {
|
|
|
7272
7271
|
readonly headersSent: boolean;
|
|
7273
7272
|
removeHeader(name: string): void;
|
|
7274
7273
|
sendDate: boolean;
|
|
7275
|
-
setHeader(name: string, value: number | string | string
|
|
7274
|
+
setHeader(name: string, value: number | string | ReadonlyArray<string>): void;
|
|
7276
7275
|
setTimeout(msecs: number, callback?: () => void): void;
|
|
7277
7276
|
socket: net.Socket | tls.TLSSocket;
|
|
7278
7277
|
statusCode: number;
|
|
@@ -7782,7 +7781,7 @@ declare module "perf_hooks" {
|
|
|
7782
7781
|
* Property buffered defaults to false.
|
|
7783
7782
|
* @param options
|
|
7784
7783
|
*/
|
|
7785
|
-
observe(options: { entryTypes: string
|
|
7784
|
+
observe(options: { entryTypes: ReadonlyArray<string>, buffered?: boolean }): void;
|
|
7786
7785
|
}
|
|
7787
7786
|
|
|
7788
7787
|
export namespace constants {
|
node v9.6/index.d.ts
CHANGED
|
@@ -28,43 +28,25 @@
|
|
|
28
28
|
// Jordi Oliveras Rovira <https://github.com/j-oliveras>
|
|
29
29
|
// Thanik Bhongbhibhat <https://github.com/bhongy>
|
|
30
30
|
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
|
31
|
-
// NOTE: These definitions support NodeJS and TypeScript 3.
|
|
31
|
+
// NOTE: These definitions support NodeJS and TypeScript 3.2.
|
|
32
32
|
|
|
33
33
|
// NOTE: TypeScript version-specific augmentations can be found in the following paths:
|
|
34
34
|
// - ~/base.d.ts - Shared definitions common to all TypeScript versions
|
|
35
35
|
// - ~/index.d.ts - Definitions specific to TypeScript 2.1
|
|
36
|
-
// - ~/ts3.
|
|
36
|
+
// - ~/ts3.2/index.d.ts - Definitions specific to TypeScript 3.2
|
|
37
37
|
|
|
38
|
-
//
|
|
39
|
-
|
|
40
|
-
// prior to TypeScript 3.1, so the older definitions will be found here.
|
|
38
|
+
// Reference required types from the default lib:
|
|
39
|
+
/// <reference lib="es2017" />
|
|
41
40
|
|
|
42
41
|
// Base definitions for all NodeJS modules that are not specific to any version of TypeScript:
|
|
43
42
|
/// <reference path="base.d.ts" />
|
|
44
43
|
|
|
45
|
-
// TypeScript 2
|
|
46
|
-
|
|
47
|
-
// Forward-declarations for needed types from es2015 and later (in case users are using `--lib es5`)
|
|
48
|
-
interface MapConstructor { }
|
|
49
|
-
interface WeakMapConstructor { }
|
|
50
|
-
interface SetConstructor { }
|
|
51
|
-
interface WeakSetConstructor { }
|
|
52
|
-
interface IteratorResult<T> { }
|
|
53
|
-
interface Iterable<T> { }
|
|
54
|
-
interface Iterator<T> {
|
|
55
|
-
next(value?: any): IteratorResult<T>;
|
|
56
|
-
}
|
|
57
|
-
interface IterableIterator<T> { }
|
|
58
|
-
interface SymbolConstructor {
|
|
59
|
-
readonly iterator: symbol;
|
|
60
|
-
}
|
|
61
|
-
declare var Symbol: SymbolConstructor;
|
|
62
|
-
|
|
44
|
+
// TypeScript 3.2-specific augmentations:
|
|
63
45
|
declare module "util" {
|
|
64
46
|
namespace inspect {
|
|
65
|
-
const custom: symbol;
|
|
47
|
+
const custom: unique symbol;
|
|
66
48
|
}
|
|
67
49
|
namespace promisify {
|
|
68
|
-
const custom: symbol;
|
|
50
|
+
const custom: unique symbol;
|
|
69
51
|
}
|
|
70
52
|
}
|
node v9.6/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "9.6.
|
|
3
|
+
"version": "9.6.61",
|
|
4
4
|
"description": "TypeScript definitions for Node.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"contributors": [
|
|
@@ -142,13 +142,6 @@
|
|
|
142
142
|
],
|
|
143
143
|
"main": "",
|
|
144
144
|
"types": "index.d.ts",
|
|
145
|
-
"typesVersions": {
|
|
146
|
-
">=3.2.0-0": {
|
|
147
|
-
"*": [
|
|
148
|
-
"ts3.2/*"
|
|
149
|
-
]
|
|
150
|
-
}
|
|
151
|
-
},
|
|
152
145
|
"repository": {
|
|
153
146
|
"type": "git",
|
|
154
147
|
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
|
|
@@ -156,6 +149,6 @@
|
|
|
156
149
|
},
|
|
157
150
|
"scripts": {},
|
|
158
151
|
"dependencies": {},
|
|
159
|
-
"typesPublisherContentHash": "
|
|
160
|
-
"typeScriptVersion": "3.
|
|
152
|
+
"typesPublisherContentHash": "41a72cfb90caeb09b8c21f90fd338195cb792d082794f0b4bb5ddb0316ff56f3",
|
|
153
|
+
"typeScriptVersion": "3.2"
|
|
161
154
|
}
|
node v9.6/ts3.2/index.d.ts
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
// NOTE: These definitions support NodeJS and TypeScript 3.2.
|
|
2
|
-
|
|
3
|
-
// NOTE: TypeScript version-specific augmentations can be found in the following paths:
|
|
4
|
-
// - ~/base.d.ts - Shared definitions common to all TypeScript versions
|
|
5
|
-
// - ~/index.d.ts - Definitions specific to TypeScript 2.1
|
|
6
|
-
// - ~/ts3.2/index.d.ts - Definitions specific to TypeScript 3.2
|
|
7
|
-
|
|
8
|
-
// Reference required types from the default lib:
|
|
9
|
-
/// <reference lib="es2017" />
|
|
10
|
-
|
|
11
|
-
// Base definitions for all NodeJS modules that are not specific to any version of TypeScript:
|
|
12
|
-
// tslint:disable-next-line:no-bad-reference
|
|
13
|
-
/// <reference path="../base.d.ts" />
|
|
14
|
-
|
|
15
|
-
// TypeScript 3.2-specific augmentations:
|
|
16
|
-
declare module "util" {
|
|
17
|
-
namespace inspect {
|
|
18
|
-
const custom: unique symbol;
|
|
19
|
-
}
|
|
20
|
-
namespace promisify {
|
|
21
|
-
const custom: unique symbol;
|
|
22
|
-
}
|
|
23
|
-
}
|