@types/node 20.17.25 → 20.17.27
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 v20.17/README.md +1 -1
- node v20.17/fs.d.ts +2 -2
- node v20.17/package.json +2 -2
- node v20.17/stream/consumers.d.ts +32 -6
node v20.17/README.md
CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for node (https://nodejs.org/).
|
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node/v20.
|
9
9
|
|
10
10
|
### Additional Details
|
11
|
-
* Last updated:
|
11
|
+
* Last updated: Mon, 24 Mar 2025 11:02:21 GMT
|
12
12
|
* Dependencies: [undici-types](https://npmjs.com/package/undici-types)
|
13
13
|
|
14
14
|
# Credits
|
node v20.17/fs.d.ts
CHANGED
@@ -4013,7 +4013,7 @@ declare module "fs" {
|
|
4013
4013
|
export function writev(
|
4014
4014
|
fd: number,
|
4015
4015
|
buffers: readonly NodeJS.ArrayBufferView[],
|
4016
|
-
position: number,
|
4016
|
+
position: number | null,
|
4017
4017
|
cb: (err: NodeJS.ErrnoException | null, bytesWritten: number, buffers: NodeJS.ArrayBufferView[]) => void,
|
4018
4018
|
): void;
|
4019
4019
|
export interface WriteVResult {
|
@@ -4058,7 +4058,7 @@ declare module "fs" {
|
|
4058
4058
|
export function readv(
|
4059
4059
|
fd: number,
|
4060
4060
|
buffers: readonly NodeJS.ArrayBufferView[],
|
4061
|
-
position: number,
|
4061
|
+
position: number | null,
|
4062
4062
|
cb: (err: NodeJS.ErrnoException | null, bytesRead: number, buffers: NodeJS.ArrayBufferView[]) => void,
|
4063
4063
|
): void;
|
4064
4064
|
export interface ReadVResult {
|
node v20.17/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@types/node",
|
3
|
-
"version": "20.17.
|
3
|
+
"version": "20.17.27",
|
4
4
|
"description": "TypeScript definitions for node",
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
|
6
6
|
"license": "MIT",
|
@@ -215,6 +215,6 @@
|
|
215
215
|
"undici-types": "~6.19.2"
|
216
216
|
},
|
217
217
|
"peerDependencies": {},
|
218
|
-
"typesPublisherContentHash": "
|
218
|
+
"typesPublisherContentHash": "c377d89f9114d74271a41a8ef892c2e9ec1a56021dd48a1abf8ab139f220fd12",
|
219
219
|
"typeScriptVersion": "5.0"
|
220
220
|
}
|
@@ -1,11 +1,37 @@
|
|
1
|
+
/**
|
2
|
+
* The utility consumer functions provide common options for consuming
|
3
|
+
* streams.
|
4
|
+
* @since v16.7.0
|
5
|
+
*/
|
1
6
|
declare module "stream/consumers" {
|
2
7
|
import { Blob as NodeBlob } from "node:buffer";
|
3
|
-
import {
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
function
|
8
|
+
import { ReadableStream as WebReadableStream } from "node:stream/web";
|
9
|
+
/**
|
10
|
+
* @since v16.7.0
|
11
|
+
* @returns Fulfills with an `ArrayBuffer` containing the full contents of the stream.
|
12
|
+
*/
|
13
|
+
function arrayBuffer(stream: WebReadableStream | NodeJS.ReadableStream | AsyncIterable<any>): Promise<ArrayBuffer>;
|
14
|
+
/**
|
15
|
+
* @since v16.7.0
|
16
|
+
* @returns Fulfills with a `Blob` containing the full contents of the stream.
|
17
|
+
*/
|
18
|
+
function blob(stream: WebReadableStream | NodeJS.ReadableStream | AsyncIterable<any>): Promise<NodeBlob>;
|
19
|
+
/**
|
20
|
+
* @since v16.7.0
|
21
|
+
* @returns Fulfills with a `Buffer` containing the full contents of the stream.
|
22
|
+
*/
|
23
|
+
function buffer(stream: WebReadableStream | NodeJS.ReadableStream | AsyncIterable<any>): Promise<Buffer>;
|
24
|
+
/**
|
25
|
+
* @since v16.7.0
|
26
|
+
* @returns Fulfills with the contents of the stream parsed as a
|
27
|
+
* UTF-8 encoded string that is then passed through `JSON.parse()`.
|
28
|
+
*/
|
29
|
+
function json(stream: WebReadableStream | NodeJS.ReadableStream | AsyncIterable<any>): Promise<unknown>;
|
30
|
+
/**
|
31
|
+
* @since v16.7.0
|
32
|
+
* @returns Fulfills with the contents of the stream parsed as a UTF-8 encoded string.
|
33
|
+
*/
|
34
|
+
function text(stream: WebReadableStream | NodeJS.ReadableStream | AsyncIterable<any>): Promise<string>;
|
9
35
|
}
|
10
36
|
declare module "node:stream/consumers" {
|
11
37
|
export * from "stream/consumers";
|