@types/node 13.13.21 → 13.13.25
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 v13.13/README.md +1 -1
- node v13.13/assert.d.ts +47 -8
- node v13.13/package.json +2 -2
- node v13.13/punycode.d.ts +56 -0
- node v13.13/ts3.4/assert.d.ts +24 -7
- node v13.13/wasi.d.ts +4 -1
- node v13.13/worker_threads.d.ts +21 -3
- node v13.13/zlib.d.ts +1 -0
node v13.13/README.md
CHANGED
|
@@ -8,7 +8,7 @@ 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/v13.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated:
|
|
11
|
+
* Last updated: Fri, 09 Oct 2020 06:51:14 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
13
|
* Global values: `Buffer`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
|
|
14
14
|
|
node v13.13/assert.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare module
|
|
1
|
+
declare module 'assert' {
|
|
2
2
|
function assert(value: any, message?: string | Error): asserts value;
|
|
3
3
|
namespace assert {
|
|
4
4
|
class AssertionError implements Error {
|
|
@@ -11,16 +11,25 @@ declare module "assert" {
|
|
|
11
11
|
code: 'ERR_ASSERTION';
|
|
12
12
|
|
|
13
13
|
constructor(options?: {
|
|
14
|
-
message?: string;
|
|
15
|
-
|
|
14
|
+
message?: string;
|
|
15
|
+
actual?: any;
|
|
16
|
+
expected?: any;
|
|
17
|
+
operator?: string;
|
|
18
|
+
stackStartFn?: Function;
|
|
16
19
|
});
|
|
17
20
|
}
|
|
18
21
|
|
|
19
|
-
type AssertPredicate = RegExp | (new() => object) | ((thrown: any) => boolean) | object | Error;
|
|
22
|
+
type AssertPredicate = RegExp | (new () => object) | ((thrown: any) => boolean) | object | Error;
|
|
20
23
|
|
|
21
24
|
function fail(message?: string | Error): never;
|
|
22
25
|
/** @deprecated since v10.0.0 - use fail([message]) or other assert functions instead. */
|
|
23
|
-
function fail(
|
|
26
|
+
function fail(
|
|
27
|
+
actual: any,
|
|
28
|
+
expected: any,
|
|
29
|
+
message?: string | Error,
|
|
30
|
+
operator?: string,
|
|
31
|
+
stackStartFn?: Function,
|
|
32
|
+
): never;
|
|
24
33
|
function ok(value: any, message?: string | Error): asserts value;
|
|
25
34
|
/** @deprecated since v9.9.0 - use strictEqual() instead. */
|
|
26
35
|
function equal(actual: any, expected: any, message?: string | Error): void;
|
|
@@ -43,14 +52,44 @@ declare module "assert" {
|
|
|
43
52
|
function ifError(value: any): asserts value is null | undefined;
|
|
44
53
|
|
|
45
54
|
function rejects(block: (() => Promise<any>) | Promise<any>, message?: string | Error): Promise<void>;
|
|
46
|
-
function rejects(
|
|
55
|
+
function rejects(
|
|
56
|
+
block: (() => Promise<any>) | Promise<any>,
|
|
57
|
+
error: AssertPredicate,
|
|
58
|
+
message?: string | Error,
|
|
59
|
+
): Promise<void>;
|
|
47
60
|
function doesNotReject(block: (() => Promise<any>) | Promise<any>, message?: string | Error): Promise<void>;
|
|
48
|
-
function doesNotReject(
|
|
61
|
+
function doesNotReject(
|
|
62
|
+
block: (() => Promise<any>) | Promise<any>,
|
|
63
|
+
error: RegExp | Function,
|
|
64
|
+
message?: string | Error,
|
|
65
|
+
): Promise<void>;
|
|
49
66
|
|
|
50
67
|
function match(value: string, regExp: RegExp, message?: string | Error): void;
|
|
51
68
|
function doesNotMatch(value: string, regExp: RegExp, message?: string | Error): void;
|
|
52
69
|
|
|
53
|
-
const strict:
|
|
70
|
+
const strict: Omit<
|
|
71
|
+
typeof assert,
|
|
72
|
+
| 'strict'
|
|
73
|
+
| 'deepEqual'
|
|
74
|
+
| 'notDeepEqual'
|
|
75
|
+
| 'equal'
|
|
76
|
+
| 'notEqual'
|
|
77
|
+
| 'ok'
|
|
78
|
+
| 'strictEqual'
|
|
79
|
+
| 'deepStrictEqual'
|
|
80
|
+
| 'ifError'
|
|
81
|
+
> & {
|
|
82
|
+
(value: any, message?: string | Error): asserts value;
|
|
83
|
+
strict: typeof strict;
|
|
84
|
+
deepEqual: typeof deepStrictEqual;
|
|
85
|
+
notDeepEqual: typeof notDeepStrictEqual;
|
|
86
|
+
equal: typeof strictEqual;
|
|
87
|
+
notEqual: typeof notStrictEqual;
|
|
88
|
+
ok(value: any, message?: string | Error): asserts value;
|
|
89
|
+
strictEqual<T>(actual: any, expected: T, message?: string | Error): asserts actual is T;
|
|
90
|
+
deepStrictEqual<T>(actual: any, expected: T, message?: string | Error): asserts actual is T;
|
|
91
|
+
ifError(value: any): asserts value is null | undefined;
|
|
92
|
+
};
|
|
54
93
|
}
|
|
55
94
|
|
|
56
95
|
export = assert;
|
node v13.13/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "13.13.
|
|
3
|
+
"version": "13.13.25",
|
|
4
4
|
"description": "TypeScript definitions for Node.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"contributors": [
|
|
@@ -241,6 +241,6 @@
|
|
|
241
241
|
},
|
|
242
242
|
"scripts": {},
|
|
243
243
|
"dependencies": {},
|
|
244
|
-
"typesPublisherContentHash": "
|
|
244
|
+
"typesPublisherContentHash": "fcd71413e6b3994cd9d832594e65a9d7f6ed4987154d3a1b163534b6de359a84",
|
|
245
245
|
"typeScriptVersion": "3.2"
|
|
246
246
|
}
|
node v13.13/punycode.d.ts
CHANGED
|
@@ -1,12 +1,68 @@
|
|
|
1
1
|
declare module "punycode" {
|
|
2
|
+
/**
|
|
3
|
+
* @deprecated since v7.0.0
|
|
4
|
+
* The version of the punycode module bundled in Node.js is being deprecated.
|
|
5
|
+
* In a future major version of Node.js this module will be removed.
|
|
6
|
+
* Users currently depending on the punycode module should switch to using
|
|
7
|
+
* the userland-provided Punycode.js module instead.
|
|
8
|
+
*/
|
|
2
9
|
function decode(string: string): string;
|
|
10
|
+
/**
|
|
11
|
+
* @deprecated since v7.0.0
|
|
12
|
+
* The version of the punycode module bundled in Node.js is being deprecated.
|
|
13
|
+
* In a future major version of Node.js this module will be removed.
|
|
14
|
+
* Users currently depending on the punycode module should switch to using
|
|
15
|
+
* the userland-provided Punycode.js module instead.
|
|
16
|
+
*/
|
|
3
17
|
function encode(string: string): string;
|
|
18
|
+
/**
|
|
19
|
+
* @deprecated since v7.0.0
|
|
20
|
+
* The version of the punycode module bundled in Node.js is being deprecated.
|
|
21
|
+
* In a future major version of Node.js this module will be removed.
|
|
22
|
+
* Users currently depending on the punycode module should switch to using
|
|
23
|
+
* the userland-provided Punycode.js module instead.
|
|
24
|
+
*/
|
|
4
25
|
function toUnicode(domain: string): string;
|
|
26
|
+
/**
|
|
27
|
+
* @deprecated since v7.0.0
|
|
28
|
+
* The version of the punycode module bundled in Node.js is being deprecated.
|
|
29
|
+
* In a future major version of Node.js this module will be removed.
|
|
30
|
+
* Users currently depending on the punycode module should switch to using
|
|
31
|
+
* the userland-provided Punycode.js module instead.
|
|
32
|
+
*/
|
|
5
33
|
function toASCII(domain: string): string;
|
|
34
|
+
/**
|
|
35
|
+
* @deprecated since v7.0.0
|
|
36
|
+
* The version of the punycode module bundled in Node.js is being deprecated.
|
|
37
|
+
* In a future major version of Node.js this module will be removed.
|
|
38
|
+
* Users currently depending on the punycode module should switch to using
|
|
39
|
+
* the userland-provided Punycode.js module instead.
|
|
40
|
+
*/
|
|
6
41
|
const ucs2: ucs2;
|
|
7
42
|
interface ucs2 {
|
|
43
|
+
/**
|
|
44
|
+
* @deprecated since v7.0.0
|
|
45
|
+
* The version of the punycode module bundled in Node.js is being deprecated.
|
|
46
|
+
* In a future major version of Node.js this module will be removed.
|
|
47
|
+
* Users currently depending on the punycode module should switch to using
|
|
48
|
+
* the userland-provided Punycode.js module instead.
|
|
49
|
+
*/
|
|
8
50
|
decode(string: string): number[];
|
|
51
|
+
/**
|
|
52
|
+
* @deprecated since v7.0.0
|
|
53
|
+
* The version of the punycode module bundled in Node.js is being deprecated.
|
|
54
|
+
* In a future major version of Node.js this module will be removed.
|
|
55
|
+
* Users currently depending on the punycode module should switch to using
|
|
56
|
+
* the userland-provided Punycode.js module instead.
|
|
57
|
+
*/
|
|
9
58
|
encode(codePoints: number[]): string;
|
|
10
59
|
}
|
|
60
|
+
/**
|
|
61
|
+
* @deprecated since v7.0.0
|
|
62
|
+
* The version of the punycode module bundled in Node.js is being deprecated.
|
|
63
|
+
* In a future major version of Node.js this module will be removed.
|
|
64
|
+
* Users currently depending on the punycode module should switch to using
|
|
65
|
+
* the userland-provided Punycode.js module instead.
|
|
66
|
+
*/
|
|
11
67
|
const version: string;
|
|
12
68
|
}
|
node v13.13/ts3.4/assert.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare module
|
|
1
|
+
declare module 'assert' {
|
|
2
2
|
function assert(value: any, message?: string | Error): void;
|
|
3
3
|
namespace assert {
|
|
4
4
|
class AssertionError implements Error {
|
|
@@ -11,16 +11,25 @@ declare module "assert" {
|
|
|
11
11
|
code: 'ERR_ASSERTION';
|
|
12
12
|
|
|
13
13
|
constructor(options?: {
|
|
14
|
-
message?: string;
|
|
15
|
-
|
|
14
|
+
message?: string;
|
|
15
|
+
actual?: any;
|
|
16
|
+
expected?: any;
|
|
17
|
+
operator?: string;
|
|
18
|
+
stackStartFn?: Function;
|
|
16
19
|
});
|
|
17
20
|
}
|
|
18
21
|
|
|
19
|
-
type AssertPredicate = RegExp | (new() => object) | ((thrown: any) => boolean) | object | Error;
|
|
22
|
+
type AssertPredicate = RegExp | (new () => object) | ((thrown: any) => boolean) | object | Error;
|
|
20
23
|
|
|
21
24
|
function fail(message?: string | Error): never;
|
|
22
25
|
/** @deprecated since v10.0.0 - use fail([message]) or other assert functions instead. */
|
|
23
|
-
function fail(
|
|
26
|
+
function fail(
|
|
27
|
+
actual: any,
|
|
28
|
+
expected: any,
|
|
29
|
+
message?: string | Error,
|
|
30
|
+
operator?: string,
|
|
31
|
+
stackStartFn?: Function,
|
|
32
|
+
): never;
|
|
24
33
|
function ok(value: any, message?: string | Error): void;
|
|
25
34
|
/** @deprecated since v9.9.0 - use strictEqual() instead. */
|
|
26
35
|
function equal(actual: any, expected: any, message?: string | Error): void;
|
|
@@ -43,9 +52,17 @@ declare module "assert" {
|
|
|
43
52
|
function ifError(value: any): void;
|
|
44
53
|
|
|
45
54
|
function rejects(block: (() => Promise<any>) | Promise<any>, message?: string | Error): Promise<void>;
|
|
46
|
-
function rejects(
|
|
55
|
+
function rejects(
|
|
56
|
+
block: (() => Promise<any>) | Promise<any>,
|
|
57
|
+
error: AssertPredicate,
|
|
58
|
+
message?: string | Error,
|
|
59
|
+
): Promise<void>;
|
|
47
60
|
function doesNotReject(block: (() => Promise<any>) | Promise<any>, message?: string | Error): Promise<void>;
|
|
48
|
-
function doesNotReject(
|
|
61
|
+
function doesNotReject(
|
|
62
|
+
block: (() => Promise<any>) | Promise<any>,
|
|
63
|
+
error: RegExp | Function,
|
|
64
|
+
message?: string | Error,
|
|
65
|
+
): Promise<void>;
|
|
49
66
|
|
|
50
67
|
function match(value: string, regExp: RegExp, message?: string | Error): void;
|
|
51
68
|
function doesNotMatch(value: string, regExp: RegExp, message?: string | Error): void;
|
node v13.13/wasi.d.ts
CHANGED
|
@@ -6,11 +6,13 @@ declare module 'wasi' {
|
|
|
6
6
|
* WASI command itself.
|
|
7
7
|
*/
|
|
8
8
|
args?: string[];
|
|
9
|
+
|
|
9
10
|
/**
|
|
10
11
|
* An object similar to `process.env` that the WebAssembly
|
|
11
12
|
* application will see as its environment.
|
|
12
13
|
*/
|
|
13
14
|
env?: object;
|
|
15
|
+
|
|
14
16
|
/**
|
|
15
17
|
* This object represents the WebAssembly application's
|
|
16
18
|
* sandbox directory structure. The string keys of `preopens` are treated as
|
|
@@ -42,9 +44,10 @@ declare module 'wasi' {
|
|
|
42
44
|
* `memory`. If `instance` does not have a `memory` export an exception is thrown.
|
|
43
45
|
*/
|
|
44
46
|
start(instance: object): void; // TODO: avoid DOM dependency until WASM moved to own lib.
|
|
47
|
+
|
|
45
48
|
/**
|
|
46
49
|
* Is an object that implements the WASI system call API. This object
|
|
47
|
-
* should be passed as the `
|
|
50
|
+
* should be passed as the `wasi_snapshot_preview1` import during the instantiation of a
|
|
48
51
|
* [`WebAssembly.Instance`][].
|
|
49
52
|
*/
|
|
50
53
|
readonly wasiImport: NodeJS.Dict<any>; // TODO: Narrow to DOM types
|
node v13.13/worker_threads.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ declare module "worker_threads" {
|
|
|
6
6
|
|
|
7
7
|
const isMainThread: boolean;
|
|
8
8
|
const parentPort: null | MessagePort;
|
|
9
|
+
const resourceLimits: ResourceLimits;
|
|
9
10
|
const SHARE_ENV: unique symbol;
|
|
10
11
|
const threadId: number;
|
|
11
12
|
const workerData: any;
|
|
@@ -15,9 +16,11 @@ declare module "worker_threads" {
|
|
|
15
16
|
readonly port2: MessagePort;
|
|
16
17
|
}
|
|
17
18
|
|
|
19
|
+
type TransferListItem = ArrayBuffer | MessagePort;
|
|
20
|
+
|
|
18
21
|
class MessagePort extends EventEmitter {
|
|
19
22
|
close(): void;
|
|
20
|
-
postMessage(value: any, transferList?:
|
|
23
|
+
postMessage(value: any, transferList?: TransferListItem[]): void;
|
|
21
24
|
ref(): void;
|
|
22
25
|
unref(): void;
|
|
23
26
|
start(): void;
|
|
@@ -74,7 +77,7 @@ declare module "worker_threads" {
|
|
|
74
77
|
/**
|
|
75
78
|
* Additional data to send in the first worker message.
|
|
76
79
|
*/
|
|
77
|
-
transferList?:
|
|
80
|
+
transferList?: TransferListItem[];
|
|
78
81
|
}
|
|
79
82
|
|
|
80
83
|
interface ResourceLimits {
|
|
@@ -83,6 +86,21 @@ declare module "worker_threads" {
|
|
|
83
86
|
codeRangeSizeMb?: number;
|
|
84
87
|
}
|
|
85
88
|
|
|
89
|
+
interface ResourceLimits {
|
|
90
|
+
/**
|
|
91
|
+
* The maximum size of a heap space for recently created objects.
|
|
92
|
+
*/
|
|
93
|
+
maxYoungGenerationSizeMb?: number;
|
|
94
|
+
/**
|
|
95
|
+
* The maximum size of the main heap in MB.
|
|
96
|
+
*/
|
|
97
|
+
maxOldGenerationSizeMb?: number;
|
|
98
|
+
/**
|
|
99
|
+
* The size of a pre-allocated memory range used for generated code.
|
|
100
|
+
*/
|
|
101
|
+
codeRangeSizeMb?: number;
|
|
102
|
+
}
|
|
103
|
+
|
|
86
104
|
class Worker extends EventEmitter {
|
|
87
105
|
readonly stdin: Writable | null;
|
|
88
106
|
readonly stdout: Readable;
|
|
@@ -97,7 +115,7 @@ declare module "worker_threads" {
|
|
|
97
115
|
*/
|
|
98
116
|
constructor(filename: string | URL, options?: WorkerOptions);
|
|
99
117
|
|
|
100
|
-
postMessage(value: any, transferList?:
|
|
118
|
+
postMessage(value: any, transferList?: TransferListItem[]): void;
|
|
101
119
|
ref(): void;
|
|
102
120
|
unref(): void;
|
|
103
121
|
/**
|
node v13.13/zlib.d.ts
CHANGED
|
@@ -19,6 +19,7 @@ declare module "zlib" {
|
|
|
19
19
|
memLevel?: number; // compression only
|
|
20
20
|
strategy?: number; // compression only
|
|
21
21
|
dictionary?: NodeJS.ArrayBufferView | ArrayBuffer; // deflate/inflate only, empty dictionary by default
|
|
22
|
+
info?: boolean;
|
|
22
23
|
}
|
|
23
24
|
|
|
24
25
|
interface BrotliOptions {
|