@types/node 14.18.6 → 15.0.0
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 v14.18 → node}/LICENSE +0 -0
- node/README.md +16 -0
- node/assert/strict.d.ts +4 -0
- node v14.18/assert.d.ts → node/assert.d.ts +8 -7
- node v14.18/async_hooks.d.ts → node/async_hooks.d.ts +11 -7
- node/base.d.ts +19 -0
- node v14.18/buffer.d.ts → node/buffer.d.ts +4 -3
- node v14.18/child_process.d.ts → node/child_process.d.ts +71 -71
- node v14.18/cluster.d.ts → node/cluster.d.ts +17 -16
- node v14.18/console.d.ts → node/console.d.ts +17 -22
- node v14.18/constants.d.ts → node/constants.d.ts +9 -8
- node v14.18/crypto.d.ts → node/crypto.d.ts +139 -54
- node v14.18/dgram.d.ts → node/dgram.d.ts +24 -23
- node/dns/promises.d.ts +101 -0
- node/dns.d.ts +326 -0
- node v14.18/domain.d.ts → node/domain.d.ts +5 -4
- node v14.18/events.d.ts → node/events.d.ts +13 -8
- node v14.18/fs/promises.d.ts → node/fs/promises.d.ts +23 -30
- node v14.18/fs.d.ts → node/fs.d.ts +85 -97
- node v14.18/globals.d.ts → node/globals.d.ts +60 -24
- {node v14.18 → node}/globals.global.d.ts +0 -0
- node v14.18/http.d.ts → node/http.d.ts +114 -178
- node v14.18/http2.d.ts → node/http2.d.ts +86 -79
- node/https.d.ts +40 -0
- node v14.18/index.d.ts → node/index.d.ts +15 -55
- node v14.18/inspector.d.ts → node/inspector.d.ts +159 -162
- node v14.18/module.d.ts → node/module.d.ts +6 -5
- node v14.18/net.d.ts → node/net.d.ts +77 -45
- node v14.18/os.d.ts → node/os.d.ts +4 -3
- node v14.18/package.json → node/package.json +25 -19
- node v14.18/path.d.ts → node/path.d.ts +10 -9
- node v14.18/perf_hooks.d.ts → node/perf_hooks.d.ts +10 -9
- node v14.18/process.d.ts → node/process.d.ts +58 -18
- node v14.18/punycode.d.ts → node/punycode.d.ts +11 -3
- node v14.18/querystring.d.ts → node/querystring.d.ts +7 -6
- node v14.18/readline.d.ts → node/readline.d.ts +19 -19
- node v14.18/repl.d.ts → node/repl.d.ts +24 -23
- node/stream/promises.d.ts +71 -0
- node v14.18/stream.d.ts → node/stream.d.ts +170 -61
- node v14.18/string_decoder.d.ts → node/string_decoder.d.ts +4 -3
- node/timers/promises.d.ts +17 -0
- node v14.18/timers.d.ts → node/timers.d.ts +20 -5
- node v14.18/tls.d.ts → node/tls.d.ts +56 -57
- node v14.18/trace_events.d.ts → node/trace_events.d.ts +4 -3
- node/ts3.6/assert.d.ts +103 -0
- node/ts3.6/base.d.ts +66 -0
- node/ts3.6/index.d.ts +7 -0
- node v14.18/tty.d.ts → node/tty.d.ts +5 -4
- node v14.18/url.d.ts → node/url.d.ts +21 -20
- node v14.18/util.d.ts → node/util.d.ts +7 -12
- node v14.18/v8.d.ts → node/v8.d.ts +5 -4
- node v14.18/vm.d.ts → node/vm.d.ts +29 -28
- node v14.18/wasi.d.ts → node/wasi.d.ts +11 -10
- node v14.18/worker_threads.d.ts → node/worker_threads.d.ts +27 -23
- node v14.18/zlib.d.ts → node/zlib.d.ts +21 -20
- node v14.18/README.md +0 -16
- node v14.18/dns.d.ts +0 -387
- node v14.18/https.d.ts +0 -142
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
declare module 'node:util' {
|
|
2
|
+
export * from 'util';
|
|
3
|
+
}
|
|
4
|
+
|
|
1
5
|
declare module 'util' {
|
|
2
6
|
interface InspectOptions extends NodeJS.InspectOptions { }
|
|
3
7
|
type Style = 'special' | 'number' | 'bigint' | 'boolean' | 'undefined' | 'null' | 'string' | 'symbol' | 'date' | 'regexp' | 'module';
|
|
@@ -7,7 +11,6 @@ declare module 'util' {
|
|
|
7
11
|
}
|
|
8
12
|
function format(format?: any, ...param: any[]): string;
|
|
9
13
|
function formatWithOptions(inspectOptions: InspectOptions, format?: any, ...param: any[]): string;
|
|
10
|
-
function getSystemErrorName(err: number): string;
|
|
11
14
|
/** @deprecated since v0.11.3 - use a third party module instead. */
|
|
12
15
|
function log(string: string): void;
|
|
13
16
|
function inspect(object: any, showHidden?: boolean, depth?: number | null, color?: boolean): string;
|
|
@@ -33,12 +36,7 @@ declare module 'util' {
|
|
|
33
36
|
/** @deprecated since v4.0.0 - use `util.types.isNativeError()` instead. */
|
|
34
37
|
function isError(object: any): object is Error;
|
|
35
38
|
function inherits(constructor: any, superConstructor: any): void;
|
|
36
|
-
|
|
37
|
-
interface DebugLogger extends DebugLoggerFunction {
|
|
38
|
-
enabled: boolean;
|
|
39
|
-
}
|
|
40
|
-
function debuglog(key: string, callback?: (fn: DebugLoggerFunction) => void): DebugLogger;
|
|
41
|
-
const debug: typeof debuglog;
|
|
39
|
+
function debuglog(key: string): (msg: string, ...param: any[]) => void;
|
|
42
40
|
/** @deprecated since v4.0.0 - use `typeof value === 'boolean'` instead. */
|
|
43
41
|
function isBoolean(object: any): object is boolean;
|
|
44
42
|
/** @deprecated since v4.0.0 - use `Buffer.isBuffer()` instead. */
|
|
@@ -185,11 +183,11 @@ declare module 'util' {
|
|
|
185
183
|
readonly ignoreBOM: boolean;
|
|
186
184
|
constructor(
|
|
187
185
|
encoding?: string,
|
|
188
|
-
options?: { fatal?: boolean
|
|
186
|
+
options?: { fatal?: boolean; ignoreBOM?: boolean }
|
|
189
187
|
);
|
|
190
188
|
decode(
|
|
191
189
|
input?: NodeJS.ArrayBufferView | ArrayBuffer | null,
|
|
192
|
-
options?: { stream?: boolean
|
|
190
|
+
options?: { stream?: boolean }
|
|
193
191
|
): string;
|
|
194
192
|
}
|
|
195
193
|
|
|
@@ -211,6 +209,3 @@ declare module 'util' {
|
|
|
211
209
|
encodeInto(input: string, output: Uint8Array): EncodeIntoResult;
|
|
212
210
|
}
|
|
213
211
|
}
|
|
214
|
-
declare module 'node:util' {
|
|
215
|
-
export * from 'util';
|
|
216
|
-
}
|
|
@@ -1,5 +1,9 @@
|
|
|
1
|
+
declare module 'node:v8' {
|
|
2
|
+
export * from 'v8';
|
|
3
|
+
}
|
|
4
|
+
|
|
1
5
|
declare module 'v8' {
|
|
2
|
-
import { Readable } from 'stream';
|
|
6
|
+
import { Readable } from 'node:stream';
|
|
3
7
|
|
|
4
8
|
interface HeapSpaceInfo {
|
|
5
9
|
space_name: string;
|
|
@@ -185,6 +189,3 @@ declare module 'v8' {
|
|
|
185
189
|
*/
|
|
186
190
|
function deserialize(data: NodeJS.TypedArray): any;
|
|
187
191
|
}
|
|
188
|
-
declare module 'node:v8' {
|
|
189
|
-
export * from 'v8';
|
|
190
|
-
}
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
declare module 'node:vm' {
|
|
2
|
+
export * from 'vm';
|
|
3
|
+
}
|
|
4
|
+
|
|
1
5
|
declare module 'vm' {
|
|
2
6
|
interface Context extends NodeJS.Dict<any> { }
|
|
3
7
|
interface BaseOptions {
|
|
@@ -5,67 +9,67 @@ declare module 'vm' {
|
|
|
5
9
|
* Specifies the filename used in stack traces produced by this script.
|
|
6
10
|
* Default: `''`.
|
|
7
11
|
*/
|
|
8
|
-
filename?: string
|
|
12
|
+
filename?: string;
|
|
9
13
|
/**
|
|
10
14
|
* Specifies the line number offset that is displayed in stack traces produced by this script.
|
|
11
15
|
* Default: `0`.
|
|
12
16
|
*/
|
|
13
|
-
lineOffset?: number
|
|
17
|
+
lineOffset?: number;
|
|
14
18
|
/**
|
|
15
19
|
* Specifies the column number offset that is displayed in stack traces produced by this script.
|
|
16
|
-
*
|
|
20
|
+
* Default: `0`
|
|
17
21
|
*/
|
|
18
|
-
columnOffset?: number
|
|
22
|
+
columnOffset?: number;
|
|
19
23
|
}
|
|
20
24
|
interface ScriptOptions extends BaseOptions {
|
|
21
|
-
displayErrors?: boolean
|
|
22
|
-
timeout?: number
|
|
23
|
-
cachedData?: Buffer
|
|
25
|
+
displayErrors?: boolean;
|
|
26
|
+
timeout?: number;
|
|
27
|
+
cachedData?: Buffer;
|
|
24
28
|
/** @deprecated in favor of `script.createCachedData()` */
|
|
25
|
-
produceCachedData?: boolean
|
|
29
|
+
produceCachedData?: boolean;
|
|
26
30
|
}
|
|
27
31
|
interface RunningScriptOptions extends BaseOptions {
|
|
28
32
|
/**
|
|
29
33
|
* When `true`, if an `Error` occurs while compiling the `code`, the line of code causing the error is attached to the stack trace.
|
|
30
34
|
* Default: `true`.
|
|
31
35
|
*/
|
|
32
|
-
displayErrors?: boolean
|
|
36
|
+
displayErrors?: boolean;
|
|
33
37
|
/**
|
|
34
38
|
* Specifies the number of milliseconds to execute code before terminating execution.
|
|
35
39
|
* If execution is terminated, an `Error` will be thrown. This value must be a strictly positive integer.
|
|
36
40
|
*/
|
|
37
|
-
timeout?: number
|
|
41
|
+
timeout?: number;
|
|
38
42
|
/**
|
|
39
43
|
* If `true`, the execution will be terminated when `SIGINT` (Ctrl+C) is received.
|
|
40
44
|
* Existing handlers for the event that have been attached via `process.on('SIGINT')` will be disabled during script execution, but will continue to work after that.
|
|
41
45
|
* If execution is terminated, an `Error` will be thrown.
|
|
42
46
|
* Default: `false`.
|
|
43
47
|
*/
|
|
44
|
-
breakOnSigint?: boolean
|
|
48
|
+
breakOnSigint?: boolean;
|
|
45
49
|
/**
|
|
46
50
|
* If set to `afterEvaluate`, microtasks will be run immediately after the script has run.
|
|
47
51
|
*/
|
|
48
|
-
microtaskMode?: 'afterEvaluate'
|
|
52
|
+
microtaskMode?: 'afterEvaluate';
|
|
49
53
|
}
|
|
50
54
|
interface CompileFunctionOptions extends BaseOptions {
|
|
51
55
|
/**
|
|
52
56
|
* Provides an optional data with V8's code cache data for the supplied source.
|
|
53
57
|
*/
|
|
54
|
-
cachedData?: Buffer
|
|
58
|
+
cachedData?: Buffer;
|
|
55
59
|
/**
|
|
56
60
|
* Specifies whether to produce new cache data.
|
|
57
61
|
* Default: `false`,
|
|
58
62
|
*/
|
|
59
|
-
produceCachedData?: boolean
|
|
63
|
+
produceCachedData?: boolean;
|
|
60
64
|
/**
|
|
61
65
|
* The sandbox/context in which the said function should be compiled in.
|
|
62
66
|
*/
|
|
63
|
-
parsingContext?: Context
|
|
67
|
+
parsingContext?: Context;
|
|
64
68
|
|
|
65
69
|
/**
|
|
66
70
|
* An array containing a collection of context extensions (objects wrapping the current scope) to be applied while compiling
|
|
67
71
|
*/
|
|
68
|
-
contextExtensions?: Object[]
|
|
72
|
+
contextExtensions?: Object[];
|
|
69
73
|
}
|
|
70
74
|
|
|
71
75
|
interface CreateContextOptions {
|
|
@@ -73,7 +77,7 @@ declare module 'vm' {
|
|
|
73
77
|
* Human-readable name of the newly created context.
|
|
74
78
|
* @default 'VM Context i' Where i is an ascending numerical index of the created context.
|
|
75
79
|
*/
|
|
76
|
-
name?: string
|
|
80
|
+
name?: string;
|
|
77
81
|
/**
|
|
78
82
|
* Corresponds to the newly created context for display purposes.
|
|
79
83
|
* The origin should be formatted like a `URL`, but with only the scheme, host, and port (if necessary),
|
|
@@ -81,24 +85,24 @@ declare module 'vm' {
|
|
|
81
85
|
* Most notably, this string should omit the trailing slash, as that denotes a path.
|
|
82
86
|
* @default ''
|
|
83
87
|
*/
|
|
84
|
-
origin?: string
|
|
88
|
+
origin?: string;
|
|
85
89
|
codeGeneration?: {
|
|
86
90
|
/**
|
|
87
91
|
* If set to false any calls to eval or function constructors (Function, GeneratorFunction, etc)
|
|
88
92
|
* will throw an EvalError.
|
|
89
93
|
* @default true
|
|
90
94
|
*/
|
|
91
|
-
strings?: boolean
|
|
95
|
+
strings?: boolean;
|
|
92
96
|
/**
|
|
93
97
|
* If set to false any attempt to compile a WebAssembly module will throw a WebAssembly.CompileError.
|
|
94
98
|
* @default true
|
|
95
99
|
*/
|
|
96
|
-
wasm?: boolean
|
|
97
|
-
}
|
|
100
|
+
wasm?: boolean;
|
|
101
|
+
};
|
|
98
102
|
/**
|
|
99
103
|
* If set to `afterEvaluate`, microtasks will be run immediately after the script has run.
|
|
100
104
|
*/
|
|
101
|
-
microtaskMode?: 'afterEvaluate'
|
|
105
|
+
microtaskMode?: 'afterEvaluate';
|
|
102
106
|
}
|
|
103
107
|
|
|
104
108
|
type MeasureMemoryMode = 'summary' | 'detailed';
|
|
@@ -107,8 +111,8 @@ declare module 'vm' {
|
|
|
107
111
|
/**
|
|
108
112
|
* @default 'summary'
|
|
109
113
|
*/
|
|
110
|
-
mode?: MeasureMemoryMode
|
|
111
|
-
context?: Context
|
|
114
|
+
mode?: MeasureMemoryMode;
|
|
115
|
+
context?: Context;
|
|
112
116
|
}
|
|
113
117
|
|
|
114
118
|
interface MemoryMeasurement {
|
|
@@ -124,7 +128,7 @@ declare module 'vm' {
|
|
|
124
128
|
runInNewContext(sandbox?: Context, options?: RunningScriptOptions): any;
|
|
125
129
|
runInThisContext(options?: RunningScriptOptions): any;
|
|
126
130
|
createCachedData(): Buffer;
|
|
127
|
-
cachedDataRejected?: boolean
|
|
131
|
+
cachedDataRejected?: boolean;
|
|
128
132
|
}
|
|
129
133
|
function createContext(sandbox?: Context, options?: CreateContextOptions): Context;
|
|
130
134
|
function isContext(sandbox: Context): boolean;
|
|
@@ -150,6 +154,3 @@ declare module 'vm' {
|
|
|
150
154
|
*/
|
|
151
155
|
function measureMemory(options?: MeasureMemoryOptions): Promise<MemoryMeasurement>;
|
|
152
156
|
}
|
|
153
|
-
declare module 'node:vm' {
|
|
154
|
-
export * from 'vm';
|
|
155
|
-
}
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
declare module 'node:wasi' {
|
|
2
|
+
export * from 'wasi';
|
|
3
|
+
}
|
|
4
|
+
|
|
1
5
|
declare module 'wasi' {
|
|
2
6
|
interface WASIOptions {
|
|
3
7
|
/**
|
|
@@ -5,13 +9,13 @@ declare module 'wasi' {
|
|
|
5
9
|
* see as command line arguments. The first argument is the virtual path to the
|
|
6
10
|
* WASI command itself.
|
|
7
11
|
*/
|
|
8
|
-
args?: string[]
|
|
12
|
+
args?: string[];
|
|
9
13
|
|
|
10
14
|
/**
|
|
11
15
|
* An object similar to `process.env` that the WebAssembly
|
|
12
16
|
* application will see as its environment.
|
|
13
17
|
*/
|
|
14
|
-
env?: object
|
|
18
|
+
env?: object;
|
|
15
19
|
|
|
16
20
|
/**
|
|
17
21
|
* This object represents the WebAssembly application's
|
|
@@ -19,7 +23,7 @@ declare module 'wasi' {
|
|
|
19
23
|
* directories within the sandbox. The corresponding values in `preopens` are
|
|
20
24
|
* the real paths to those directories on the host machine.
|
|
21
25
|
*/
|
|
22
|
-
preopens?: NodeJS.Dict<string
|
|
26
|
+
preopens?: NodeJS.Dict<string>;
|
|
23
27
|
|
|
24
28
|
/**
|
|
25
29
|
* By default, WASI applications terminate the Node.js
|
|
@@ -28,25 +32,25 @@ declare module 'wasi' {
|
|
|
28
32
|
* process.
|
|
29
33
|
* @default false
|
|
30
34
|
*/
|
|
31
|
-
returnOnExit?: boolean
|
|
35
|
+
returnOnExit?: boolean;
|
|
32
36
|
|
|
33
37
|
/**
|
|
34
38
|
* The file descriptor used as standard input in the WebAssembly application.
|
|
35
39
|
* @default 0
|
|
36
40
|
*/
|
|
37
|
-
stdin?: number
|
|
41
|
+
stdin?: number;
|
|
38
42
|
|
|
39
43
|
/**
|
|
40
44
|
* The file descriptor used as standard output in the WebAssembly application.
|
|
41
45
|
* @default 1
|
|
42
46
|
*/
|
|
43
|
-
stdout?: number
|
|
47
|
+
stdout?: number;
|
|
44
48
|
|
|
45
49
|
/**
|
|
46
50
|
* The file descriptor used as standard error in the WebAssembly application.
|
|
47
51
|
* @default 2
|
|
48
52
|
*/
|
|
49
|
-
stderr?: number
|
|
53
|
+
stderr?: number;
|
|
50
54
|
}
|
|
51
55
|
|
|
52
56
|
class WASI {
|
|
@@ -84,6 +88,3 @@ declare module 'wasi' {
|
|
|
84
88
|
readonly wasiImport: NodeJS.Dict<any>; // TODO: Narrow to DOM types
|
|
85
89
|
}
|
|
86
90
|
}
|
|
87
|
-
declare module 'node:wasi' {
|
|
88
|
-
export * from 'wasi';
|
|
89
|
-
}
|
|
@@ -1,9 +1,13 @@
|
|
|
1
|
+
declare module 'node:worker_threads' {
|
|
2
|
+
export * from 'worker_threads';
|
|
3
|
+
}
|
|
4
|
+
|
|
1
5
|
declare module 'worker_threads' {
|
|
2
|
-
import { Context } from 'vm';
|
|
3
|
-
import EventEmitter = require('events');
|
|
4
|
-
import { Readable, Writable } from 'stream';
|
|
5
|
-
import { URL } from 'url';
|
|
6
|
-
import { FileHandle } from 'fs/promises';
|
|
6
|
+
import { Context } from 'node:vm';
|
|
7
|
+
import EventEmitter = require('node:events');
|
|
8
|
+
import { Readable, Writable } from 'node:stream';
|
|
9
|
+
import { URL } from 'node:url';
|
|
10
|
+
import { FileHandle } from 'node:fs/promises';
|
|
7
11
|
|
|
8
12
|
const isMainThread: boolean;
|
|
9
13
|
const parentPort: null | MessagePort;
|
|
@@ -74,40 +78,43 @@ declare module 'worker_threads' {
|
|
|
74
78
|
* but the values will be available on the global `process.argv` as if they
|
|
75
79
|
* were passed as CLI options to the script.
|
|
76
80
|
*/
|
|
77
|
-
argv?: any[]
|
|
78
|
-
env?: NodeJS.Dict<string> | typeof SHARE_ENV
|
|
79
|
-
eval?: boolean
|
|
81
|
+
argv?: any[];
|
|
82
|
+
env?: NodeJS.Dict<string> | typeof SHARE_ENV;
|
|
83
|
+
eval?: boolean;
|
|
80
84
|
workerData?: any;
|
|
81
|
-
stdin?: boolean
|
|
82
|
-
stdout?: boolean
|
|
83
|
-
stderr?: boolean
|
|
84
|
-
execArgv?: string[]
|
|
85
|
-
resourceLimits?: ResourceLimits
|
|
85
|
+
stdin?: boolean;
|
|
86
|
+
stdout?: boolean;
|
|
87
|
+
stderr?: boolean;
|
|
88
|
+
execArgv?: string[];
|
|
89
|
+
resourceLimits?: ResourceLimits;
|
|
86
90
|
/**
|
|
87
91
|
* Additional data to send in the first worker message.
|
|
88
92
|
*/
|
|
89
|
-
transferList?: TransferListItem[]
|
|
90
|
-
|
|
93
|
+
transferList?: TransferListItem[];
|
|
94
|
+
/**
|
|
95
|
+
* @default true
|
|
96
|
+
*/
|
|
97
|
+
trackUnmanagedFds?: boolean;
|
|
91
98
|
}
|
|
92
99
|
|
|
93
100
|
interface ResourceLimits {
|
|
94
101
|
/**
|
|
95
102
|
* The maximum size of a heap space for recently created objects.
|
|
96
103
|
*/
|
|
97
|
-
maxYoungGenerationSizeMb?: number
|
|
104
|
+
maxYoungGenerationSizeMb?: number;
|
|
98
105
|
/**
|
|
99
106
|
* The maximum size of the main heap in MB.
|
|
100
107
|
*/
|
|
101
|
-
maxOldGenerationSizeMb?: number
|
|
108
|
+
maxOldGenerationSizeMb?: number;
|
|
102
109
|
/**
|
|
103
110
|
* The size of a pre-allocated memory range used for generated code.
|
|
104
111
|
*/
|
|
105
|
-
codeRangeSizeMb?: number
|
|
112
|
+
codeRangeSizeMb?: number;
|
|
106
113
|
/**
|
|
107
114
|
* The default maximum stack size for the thread. Small values may lead to unusable Worker instances.
|
|
108
115
|
* @default 4
|
|
109
116
|
*/
|
|
110
|
-
stackSizeMb?: number
|
|
117
|
+
stackSizeMb?: number;
|
|
111
118
|
}
|
|
112
119
|
|
|
113
120
|
class Worker extends EventEmitter {
|
|
@@ -115,7 +122,7 @@ declare module 'worker_threads' {
|
|
|
115
122
|
readonly stdout: Readable;
|
|
116
123
|
readonly stderr: Readable;
|
|
117
124
|
readonly threadId: number;
|
|
118
|
-
readonly resourceLimits?: ResourceLimits
|
|
125
|
+
readonly resourceLimits?: ResourceLimits;
|
|
119
126
|
|
|
120
127
|
/**
|
|
121
128
|
* @param filename The path to the Worker’s main script or module.
|
|
@@ -236,6 +243,3 @@ declare module 'worker_threads' {
|
|
|
236
243
|
*/
|
|
237
244
|
function receiveMessageOnPort(port: MessagePort): { message: any } | undefined;
|
|
238
245
|
}
|
|
239
|
-
declare module 'node:worker_threads' {
|
|
240
|
-
export * from 'worker_threads';
|
|
241
|
-
}
|
|
@@ -1,55 +1,59 @@
|
|
|
1
|
+
declare module 'node:zlib' {
|
|
2
|
+
export * from 'zlib';
|
|
3
|
+
}
|
|
4
|
+
|
|
1
5
|
declare module 'zlib' {
|
|
2
|
-
import * as stream from 'stream';
|
|
6
|
+
import * as stream from 'node:stream';
|
|
3
7
|
|
|
4
8
|
interface ZlibOptions {
|
|
5
9
|
/**
|
|
6
10
|
* @default constants.Z_NO_FLUSH
|
|
7
11
|
*/
|
|
8
|
-
flush?: number
|
|
12
|
+
flush?: number;
|
|
9
13
|
/**
|
|
10
14
|
* @default constants.Z_FINISH
|
|
11
15
|
*/
|
|
12
|
-
finishFlush?: number
|
|
16
|
+
finishFlush?: number;
|
|
13
17
|
/**
|
|
14
18
|
* @default 16*1024
|
|
15
19
|
*/
|
|
16
|
-
chunkSize?: number
|
|
17
|
-
windowBits?: number
|
|
18
|
-
level?: number
|
|
19
|
-
memLevel?: number
|
|
20
|
-
strategy?: number
|
|
21
|
-
dictionary?: NodeJS.ArrayBufferView | ArrayBuffer
|
|
22
|
-
info?: boolean
|
|
23
|
-
maxOutputLength?: number
|
|
20
|
+
chunkSize?: number;
|
|
21
|
+
windowBits?: number;
|
|
22
|
+
level?: number; // compression only
|
|
23
|
+
memLevel?: number; // compression only
|
|
24
|
+
strategy?: number; // compression only
|
|
25
|
+
dictionary?: NodeJS.ArrayBufferView | ArrayBuffer; // deflate/inflate only, empty dictionary by default
|
|
26
|
+
info?: boolean;
|
|
27
|
+
maxOutputLength?: number;
|
|
24
28
|
}
|
|
25
29
|
|
|
26
30
|
interface BrotliOptions {
|
|
27
31
|
/**
|
|
28
32
|
* @default constants.BROTLI_OPERATION_PROCESS
|
|
29
33
|
*/
|
|
30
|
-
flush?: number
|
|
34
|
+
flush?: number;
|
|
31
35
|
/**
|
|
32
36
|
* @default constants.BROTLI_OPERATION_FINISH
|
|
33
37
|
*/
|
|
34
|
-
finishFlush?: number
|
|
38
|
+
finishFlush?: number;
|
|
35
39
|
/**
|
|
36
40
|
* @default 16*1024
|
|
37
41
|
*/
|
|
38
|
-
chunkSize?: number
|
|
42
|
+
chunkSize?: number;
|
|
39
43
|
params?: {
|
|
40
44
|
/**
|
|
41
45
|
* Each key is a `constants.BROTLI_*` constant.
|
|
42
46
|
*/
|
|
43
47
|
[key: number]: boolean | number;
|
|
44
|
-
}
|
|
45
|
-
maxOutputLength?: number
|
|
48
|
+
};
|
|
49
|
+
maxOutputLength?: number;
|
|
46
50
|
}
|
|
47
51
|
|
|
48
52
|
interface Zlib {
|
|
49
53
|
/** @deprecated Use bytesWritten instead. */
|
|
50
54
|
readonly bytesRead: number;
|
|
51
55
|
readonly bytesWritten: number;
|
|
52
|
-
shell?: boolean | string
|
|
56
|
+
shell?: boolean | string;
|
|
53
57
|
close(callback?: () => void): void;
|
|
54
58
|
flush(kind?: number, callback?: () => void): void;
|
|
55
59
|
flush(callback?: () => void): void;
|
|
@@ -359,6 +363,3 @@ declare module 'zlib' {
|
|
|
359
363
|
/** @deprecated */
|
|
360
364
|
const Z_DEFLATED: number;
|
|
361
365
|
}
|
|
362
|
-
declare module 'node:zlib' {
|
|
363
|
-
export * from 'zlib';
|
|
364
|
-
}
|
node v14.18/README.md
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
# Installation
|
|
2
|
-
> `npm install --save @types/node`
|
|
3
|
-
|
|
4
|
-
# Summary
|
|
5
|
-
This package contains type definitions for Node.js (https://nodejs.org/).
|
|
6
|
-
|
|
7
|
-
# Details
|
|
8
|
-
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node/v14.
|
|
9
|
-
|
|
10
|
-
### Additional Details
|
|
11
|
-
* Last updated: Mon, 17 Jan 2022 09:01:29 GMT
|
|
12
|
-
* Dependencies: none
|
|
13
|
-
* Global values: `Buffer`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
|
|
14
|
-
|
|
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), [Seth Westphal](https://github.com/westy92), [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), [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), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [Bond](https://github.com/bondz), and [Linus Unnebäck](https://github.com/LinusU).
|