@types/node 20.1.5 → 20.1.7
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/buffer.d.ts +2 -2
- node/package.json +2 -2
- node/test.d.ts +12 -17
- node/ts4.8/buffer.d.ts +2 -2
- node/ts4.8/url.d.ts +3 -3
- node/ts4.8/util.d.ts +1 -1
- node/url.d.ts +3 -3
- node/util.d.ts +1 -1
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: Tue, 16 May 2023
|
|
11
|
+
* Last updated: Tue, 16 May 2023 20:02:56 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
13
|
* Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`, `structuredClone`
|
|
14
14
|
|
node/buffer.d.ts
CHANGED
|
@@ -2309,7 +2309,7 @@ declare module 'buffer' {
|
|
|
2309
2309
|
* **For code running using Node.js APIs, converting between base64-encoded strings**
|
|
2310
2310
|
* **and binary data should be performed using `Buffer.from(str, 'base64')` and`buf.toString('base64')`.**
|
|
2311
2311
|
* @since v15.13.0, v14.17.0
|
|
2312
|
-
* @
|
|
2312
|
+
* @legacy Use `Buffer.from(data, 'base64')` instead.
|
|
2313
2313
|
* @param data The Base64-encoded input string.
|
|
2314
2314
|
*/
|
|
2315
2315
|
function atob(data: string): string;
|
|
@@ -2325,7 +2325,7 @@ declare module 'buffer' {
|
|
|
2325
2325
|
* **For code running using Node.js APIs, converting between base64-encoded strings**
|
|
2326
2326
|
* **and binary data should be performed using `Buffer.from(str, 'base64')` and`buf.toString('base64')`.**
|
|
2327
2327
|
* @since v15.13.0, v14.17.0
|
|
2328
|
-
* @
|
|
2328
|
+
* @legacy Use `buf.toString('base64')` instead.
|
|
2329
2329
|
* @param data An ASCII (Latin1) string.
|
|
2330
2330
|
*/
|
|
2331
2331
|
function btoa(data: string): string;
|
node/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "20.1.
|
|
3
|
+
"version": "20.1.7",
|
|
4
4
|
"description": "TypeScript definitions for Node.js",
|
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
|
|
6
6
|
"license": "MIT",
|
|
@@ -232,6 +232,6 @@
|
|
|
232
232
|
},
|
|
233
233
|
"scripts": {},
|
|
234
234
|
"dependencies": {},
|
|
235
|
-
"typesPublisherContentHash": "
|
|
235
|
+
"typesPublisherContentHash": "66c03deccac83a7d603defb282c78bd668ddc17b46fda8c94bc538f577bb3567",
|
|
236
236
|
"typeScriptVersion": "4.3"
|
|
237
237
|
}
|
node/test.d.ts
CHANGED
|
@@ -171,21 +171,21 @@ declare module 'node:test' {
|
|
|
171
171
|
* The `it()` function is imported from the `node:test` module.
|
|
172
172
|
* @since v18.6.0, v16.17.0
|
|
173
173
|
*/
|
|
174
|
-
function it(name?: string, options?: TestOptions, fn?:
|
|
175
|
-
function it(name?: string, fn?:
|
|
176
|
-
function it(options?: TestOptions, fn?:
|
|
177
|
-
function it(fn?:
|
|
174
|
+
function it(name?: string, options?: TestOptions, fn?: TestFn): void;
|
|
175
|
+
function it(name?: string, fn?: TestFn): void;
|
|
176
|
+
function it(options?: TestOptions, fn?: TestFn): void;
|
|
177
|
+
function it(fn?: TestFn): void;
|
|
178
178
|
namespace it {
|
|
179
179
|
// Shorthand for skipping a test, same as `it([name], { skip: true }[, fn])`.
|
|
180
|
-
function skip(name?: string, options?: TestOptions, fn?:
|
|
181
|
-
function skip(name?: string, fn?:
|
|
182
|
-
function skip(options?: TestOptions, fn?:
|
|
183
|
-
function skip(fn?:
|
|
180
|
+
function skip(name?: string, options?: TestOptions, fn?: TestFn): void;
|
|
181
|
+
function skip(name?: string, fn?: TestFn): void;
|
|
182
|
+
function skip(options?: TestOptions, fn?: TestFn): void;
|
|
183
|
+
function skip(fn?: TestFn): void;
|
|
184
184
|
// Shorthand for marking a test as `TODO`, same as `it([name], { todo: true }[, fn])`.
|
|
185
|
-
function todo(name?: string, options?: TestOptions, fn?:
|
|
186
|
-
function todo(name?: string, fn?:
|
|
187
|
-
function todo(options?: TestOptions, fn?:
|
|
188
|
-
function todo(fn?:
|
|
185
|
+
function todo(name?: string, options?: TestOptions, fn?: TestFn): void;
|
|
186
|
+
function todo(name?: string, fn?: TestFn): void;
|
|
187
|
+
function todo(options?: TestOptions, fn?: TestFn): void;
|
|
188
|
+
function todo(fn?: TestFn): void;
|
|
189
189
|
}
|
|
190
190
|
/**
|
|
191
191
|
* The type of a function under test. The first argument to this function is a
|
|
@@ -198,11 +198,6 @@ declare module 'node:test' {
|
|
|
198
198
|
* If the test uses callbacks, the callback function is passed as an argument
|
|
199
199
|
*/
|
|
200
200
|
type SuiteFn = (done: (result?: any) => void) => void;
|
|
201
|
-
/**
|
|
202
|
-
* The type of a function under test.
|
|
203
|
-
* If the test uses callbacks, the callback function is passed as an argument
|
|
204
|
-
*/
|
|
205
|
-
type ItFn = (done: (result?: any) => void) => any;
|
|
206
201
|
interface RunOptions {
|
|
207
202
|
/**
|
|
208
203
|
* If a number is provided, then that many files would run in parallel.
|
node/ts4.8/buffer.d.ts
CHANGED
|
@@ -2309,7 +2309,7 @@ declare module 'buffer' {
|
|
|
2309
2309
|
* **For code running using Node.js APIs, converting between base64-encoded strings**
|
|
2310
2310
|
* **and binary data should be performed using `Buffer.from(str, 'base64')` and`buf.toString('base64')`.**
|
|
2311
2311
|
* @since v15.13.0, v14.17.0
|
|
2312
|
-
* @
|
|
2312
|
+
* @legacy Use `Buffer.from(data, 'base64')` instead.
|
|
2313
2313
|
* @param data The Base64-encoded input string.
|
|
2314
2314
|
*/
|
|
2315
2315
|
function atob(data: string): string;
|
|
@@ -2325,7 +2325,7 @@ declare module 'buffer' {
|
|
|
2325
2325
|
* **For code running using Node.js APIs, converting between base64-encoded strings**
|
|
2326
2326
|
* **and binary data should be performed using `Buffer.from(str, 'base64')` and`buf.toString('base64')`.**
|
|
2327
2327
|
* @since v15.13.0, v14.17.0
|
|
2328
|
-
* @
|
|
2328
|
+
* @legacy Use `buf.toString('base64')` instead.
|
|
2329
2329
|
* @param data An ASCII (Latin1) string.
|
|
2330
2330
|
*/
|
|
2331
2331
|
function btoa(data: string): string;
|
node/ts4.8/url.d.ts
CHANGED
|
@@ -129,7 +129,7 @@ declare module 'url' {
|
|
|
129
129
|
* string, an `Error` is thrown.
|
|
130
130
|
* * `result` is returned.
|
|
131
131
|
* @since v0.1.25
|
|
132
|
-
* @
|
|
132
|
+
* @legacy Use the WHATWG URL API instead.
|
|
133
133
|
* @param urlObject A URL object (as returned by `url.parse()` or constructed otherwise). If a string, it is converted to an object by passing it to `url.parse()`.
|
|
134
134
|
*/
|
|
135
135
|
function format(urlObject: URL, options?: URLFormatOptions): string;
|
|
@@ -193,7 +193,7 @@ declare module 'url' {
|
|
|
193
193
|
* string, an `Error` is thrown.
|
|
194
194
|
* * `result` is returned.
|
|
195
195
|
* @since v0.1.25
|
|
196
|
-
* @
|
|
196
|
+
* @legacy Use the WHATWG URL API instead.
|
|
197
197
|
* @param urlObject A URL object (as returned by `url.parse()` or constructed otherwise). If a string, it is converted to an object by passing it to `url.parse()`.
|
|
198
198
|
*/
|
|
199
199
|
function format(urlObject: UrlObject | string): string;
|
|
@@ -226,7 +226,7 @@ declare module 'url' {
|
|
|
226
226
|
* resolve('http://example.com/one', '/two'); // 'http://example.com/two'
|
|
227
227
|
* ```
|
|
228
228
|
* @since v0.1.25
|
|
229
|
-
* @
|
|
229
|
+
* @legacy Use the WHATWG URL API instead.
|
|
230
230
|
* @param from The base URL to use if `to` is a relative URL.
|
|
231
231
|
* @param to The target URL to resolve.
|
|
232
232
|
*/
|
node/ts4.8/util.d.ts
CHANGED
|
@@ -575,7 +575,7 @@ declare module 'util' {
|
|
|
575
575
|
* stream.write('With ES6');
|
|
576
576
|
* ```
|
|
577
577
|
* @since v0.3.0
|
|
578
|
-
* @
|
|
578
|
+
* @legacy Use ES2015 class syntax and `extends` keyword instead.
|
|
579
579
|
*/
|
|
580
580
|
export function inherits(constructor: unknown, superConstructor: unknown): void;
|
|
581
581
|
export type DebugLoggerFunction = (msg: string, ...param: unknown[]) => void;
|
node/url.d.ts
CHANGED
|
@@ -129,7 +129,7 @@ declare module 'url' {
|
|
|
129
129
|
* string, an `Error` is thrown.
|
|
130
130
|
* * `result` is returned.
|
|
131
131
|
* @since v0.1.25
|
|
132
|
-
* @
|
|
132
|
+
* @legacy Use the WHATWG URL API instead.
|
|
133
133
|
* @param urlObject A URL object (as returned by `url.parse()` or constructed otherwise). If a string, it is converted to an object by passing it to `url.parse()`.
|
|
134
134
|
*/
|
|
135
135
|
function format(urlObject: URL, options?: URLFormatOptions): string;
|
|
@@ -193,7 +193,7 @@ declare module 'url' {
|
|
|
193
193
|
* string, an `Error` is thrown.
|
|
194
194
|
* * `result` is returned.
|
|
195
195
|
* @since v0.1.25
|
|
196
|
-
* @
|
|
196
|
+
* @legacy Use the WHATWG URL API instead.
|
|
197
197
|
* @param urlObject A URL object (as returned by `url.parse()` or constructed otherwise). If a string, it is converted to an object by passing it to `url.parse()`.
|
|
198
198
|
*/
|
|
199
199
|
function format(urlObject: UrlObject | string): string;
|
|
@@ -226,7 +226,7 @@ declare module 'url' {
|
|
|
226
226
|
* resolve('http://example.com/one', '/two'); // 'http://example.com/two'
|
|
227
227
|
* ```
|
|
228
228
|
* @since v0.1.25
|
|
229
|
-
* @
|
|
229
|
+
* @legacy Use the WHATWG URL API instead.
|
|
230
230
|
* @param from The base URL to use if `to` is a relative URL.
|
|
231
231
|
* @param to The target URL to resolve.
|
|
232
232
|
*/
|
node/util.d.ts
CHANGED
|
@@ -575,7 +575,7 @@ declare module 'util' {
|
|
|
575
575
|
* stream.write('With ES6');
|
|
576
576
|
* ```
|
|
577
577
|
* @since v0.3.0
|
|
578
|
-
* @
|
|
578
|
+
* @legacy Use ES2015 class syntax and `extends` keyword instead.
|
|
579
579
|
*/
|
|
580
580
|
export function inherits(constructor: unknown, superConstructor: unknown): void;
|
|
581
581
|
export type DebugLoggerFunction = (msg: string, ...param: unknown[]) => void;
|