@types/node 18.7.3 → 18.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 +1 -1
- node/crypto.d.ts +2 -2
- node/fs/promises.d.ts +20 -15
- node/package.json +2 -2
- node/perf_hooks.d.ts +13 -3
node/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This package contains type definitions for Node.js (https://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:
|
|
11
|
+
* Last updated: Tue, 16 Aug 2022 14:02:31 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
13
|
* Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`, `structuredClone`
|
|
14
14
|
|
node/crypto.d.ts
CHANGED
|
@@ -2309,11 +2309,11 @@ declare module 'crypto' {
|
|
|
2309
2309
|
* If `encoding` is specified, a string is returned; otherwise a `Buffer` is
|
|
2310
2310
|
* returned.
|
|
2311
2311
|
* @since v0.11.14
|
|
2312
|
-
* @param encoding The `encoding` of the return value.
|
|
2312
|
+
* @param [encoding] The `encoding` of the return value.
|
|
2313
2313
|
* @param [format='uncompressed']
|
|
2314
2314
|
* @return The EC Diffie-Hellman public key in the specified `encoding` and `format`.
|
|
2315
2315
|
*/
|
|
2316
|
-
getPublicKey(): Buffer;
|
|
2316
|
+
getPublicKey(encoding?: null, format?: ECDHKeyFormat): Buffer;
|
|
2317
2317
|
getPublicKey(encoding: BinaryToTextEncoding, format?: ECDHKeyFormat): string;
|
|
2318
2318
|
/**
|
|
2319
2319
|
* Sets the EC Diffie-Hellman private key.
|
node/fs/promises.d.ts
CHANGED
|
@@ -13,29 +13,31 @@ declare module 'fs/promises' {
|
|
|
13
13
|
import { Stream } from 'node:stream';
|
|
14
14
|
import { ReadableStream } from 'node:stream/web';
|
|
15
15
|
import {
|
|
16
|
-
Stats,
|
|
17
16
|
BigIntStats,
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
PathLike,
|
|
22
|
-
RmDirOptions,
|
|
23
|
-
RmOptions,
|
|
24
|
-
MakeDirectoryOptions,
|
|
25
|
-
Dirent,
|
|
26
|
-
OpenDirOptions,
|
|
17
|
+
BufferEncodingOption,
|
|
18
|
+
constants as fsConstants,
|
|
19
|
+
CopyOptions,
|
|
27
20
|
Dir,
|
|
21
|
+
Dirent,
|
|
22
|
+
MakeDirectoryOptions,
|
|
23
|
+
Mode,
|
|
28
24
|
ObjectEncodingOptions,
|
|
29
|
-
|
|
25
|
+
OpenDirOptions,
|
|
30
26
|
OpenMode,
|
|
31
|
-
|
|
32
|
-
WatchOptions,
|
|
33
|
-
WatchEventType,
|
|
34
|
-
CopyOptions,
|
|
27
|
+
PathLike,
|
|
35
28
|
ReadStream,
|
|
29
|
+
ReadVResult,
|
|
30
|
+
RmDirOptions,
|
|
31
|
+
RmOptions,
|
|
32
|
+
StatOptions,
|
|
33
|
+
Stats,
|
|
36
34
|
TimeLike,
|
|
35
|
+
WatchEventType,
|
|
36
|
+
WatchOptions,
|
|
37
37
|
WriteStream,
|
|
38
|
+
WriteVResult,
|
|
38
39
|
} from 'node:fs';
|
|
40
|
+
|
|
39
41
|
interface FileChangeInfo<T extends string | Buffer> {
|
|
40
42
|
eventType: WatchEventType;
|
|
41
43
|
filename: T;
|
|
@@ -427,6 +429,9 @@ declare module 'fs/promises' {
|
|
|
427
429
|
*/
|
|
428
430
|
close(): Promise<void>;
|
|
429
431
|
}
|
|
432
|
+
|
|
433
|
+
const constants: typeof fsConstants;
|
|
434
|
+
|
|
430
435
|
/**
|
|
431
436
|
* Tests a user's permissions for the file or directory specified by `path`.
|
|
432
437
|
* The `mode` argument is an optional integer that specifies the accessibility
|
node/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "18.7.
|
|
3
|
+
"version": "18.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",
|
|
@@ -220,6 +220,6 @@
|
|
|
220
220
|
},
|
|
221
221
|
"scripts": {},
|
|
222
222
|
"dependencies": {},
|
|
223
|
-
"typesPublisherContentHash": "
|
|
223
|
+
"typesPublisherContentHash": "cd432c68b37a5e2bdfd29e94c83191aa3220708137ac9cad45a6d88d2f8f9b17",
|
|
224
224
|
"typeScriptVersion": "4.0"
|
|
225
225
|
}
|
node/perf_hooks.d.ts
CHANGED
|
@@ -85,6 +85,14 @@ declare module 'perf_hooks' {
|
|
|
85
85
|
* @since v16.0.0
|
|
86
86
|
*/
|
|
87
87
|
readonly detail?: NodeGCPerformanceDetail | unknown | undefined; // TODO: Narrow this based on entry type.
|
|
88
|
+
toJSON(): any;
|
|
89
|
+
}
|
|
90
|
+
class PerformanceMark extends PerformanceEntry {
|
|
91
|
+
readonly duration: 0;
|
|
92
|
+
readonly entryType: 'mark';
|
|
93
|
+
}
|
|
94
|
+
class PerformanceMeasure extends PerformanceEntry {
|
|
95
|
+
readonly entryType: 'measure';
|
|
88
96
|
}
|
|
89
97
|
/**
|
|
90
98
|
* _This property is an extension by Node.js. It is not available in Web browsers._
|
|
@@ -226,8 +234,9 @@ declare module 'perf_hooks' {
|
|
|
226
234
|
* and whose performanceEntry.duration is always 0.
|
|
227
235
|
* Performance marks are used to mark specific significant moments in the Performance Timeline.
|
|
228
236
|
* @param name
|
|
237
|
+
* @return The PerformanceMark entry that was created
|
|
229
238
|
*/
|
|
230
|
-
mark(name?: string, options?: MarkOptions):
|
|
239
|
+
mark(name?: string, options?: MarkOptions): PerformanceMark;
|
|
231
240
|
/**
|
|
232
241
|
* Creates a new PerformanceMeasure entry in the Performance Timeline.
|
|
233
242
|
* A PerformanceMeasure is a subclass of PerformanceEntry whose performanceEntry.entryType is always 'measure',
|
|
@@ -242,9 +251,10 @@ declare module 'perf_hooks' {
|
|
|
242
251
|
* @param name
|
|
243
252
|
* @param startMark
|
|
244
253
|
* @param endMark
|
|
254
|
+
* @return The PerformanceMeasure entry that was created
|
|
245
255
|
*/
|
|
246
|
-
measure(name: string, startMark?: string, endMark?: string):
|
|
247
|
-
measure(name: string, options: MeasureOptions):
|
|
256
|
+
measure(name: string, startMark?: string, endMark?: string): PerformanceMeasure;
|
|
257
|
+
measure(name: string, options: MeasureOptions): PerformanceMeasure;
|
|
248
258
|
/**
|
|
249
259
|
* An instance of the PerformanceNodeTiming class that provides performance metrics for specific Node.js operational milestones.
|
|
250
260
|
*/
|