@types/node 18.19.93 → 18.19.95
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 v18.19/README.md +1 -1
- node v18.19/cluster.d.ts +1 -1
- node v18.19/fs.d.ts +44 -0
- node v18.19/package.json +2 -2
node v18.19/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/v18.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated:
|
|
11
|
+
* Last updated: Tue, 06 May 2025 02:14:23 GMT
|
|
12
12
|
* Dependencies: [undici-types](https://npmjs.com/package/undici-types)
|
|
13
13
|
|
|
14
14
|
# Credits
|
node v18.19/cluster.d.ts
CHANGED
|
@@ -265,7 +265,7 @@ declare module "cluster" {
|
|
|
265
265
|
* @since v0.7.7
|
|
266
266
|
* @return A reference to `worker`.
|
|
267
267
|
*/
|
|
268
|
-
disconnect():
|
|
268
|
+
disconnect(): this;
|
|
269
269
|
/**
|
|
270
270
|
* This function returns `true` if the worker is connected to its primary via its
|
|
271
271
|
* IPC channel, `false` otherwise. A worker is connected to its primary after it
|
node v18.19/fs.d.ts
CHANGED
|
@@ -2337,6 +2337,20 @@ declare module "fs" {
|
|
|
2337
2337
|
* @since v0.1.96
|
|
2338
2338
|
*/
|
|
2339
2339
|
export function fsyncSync(fd: number): void;
|
|
2340
|
+
export interface WriteOptions {
|
|
2341
|
+
/**
|
|
2342
|
+
* @default 0
|
|
2343
|
+
*/
|
|
2344
|
+
offset?: number | undefined;
|
|
2345
|
+
/**
|
|
2346
|
+
* @default `buffer.byteLength - offset`
|
|
2347
|
+
*/
|
|
2348
|
+
length?: number | undefined;
|
|
2349
|
+
/**
|
|
2350
|
+
* @default null
|
|
2351
|
+
*/
|
|
2352
|
+
position?: number | undefined | null;
|
|
2353
|
+
}
|
|
2340
2354
|
/**
|
|
2341
2355
|
* Write `buffer` to the file specified by `fd`.
|
|
2342
2356
|
*
|
|
@@ -2402,6 +2416,20 @@ declare module "fs" {
|
|
|
2402
2416
|
buffer: TBuffer,
|
|
2403
2417
|
callback: (err: NodeJS.ErrnoException | null, written: number, buffer: TBuffer) => void,
|
|
2404
2418
|
): void;
|
|
2419
|
+
/**
|
|
2420
|
+
* Asynchronously writes `buffer` to the file referenced by the supplied file descriptor.
|
|
2421
|
+
* @param fd A file descriptor.
|
|
2422
|
+
* @param options An object with the following properties:
|
|
2423
|
+
* * `offset` The part of the buffer to be written. If not supplied, defaults to `0`.
|
|
2424
|
+
* * `length` The number of bytes to write. If not supplied, defaults to `buffer.length - offset`.
|
|
2425
|
+
* * `position` The offset from the beginning of the file where this data should be written. If not supplied, defaults to the current position.
|
|
2426
|
+
*/
|
|
2427
|
+
export function write<TBuffer extends NodeJS.ArrayBufferView>(
|
|
2428
|
+
fd: number,
|
|
2429
|
+
buffer: TBuffer,
|
|
2430
|
+
options: WriteOptions,
|
|
2431
|
+
callback: (err: NodeJS.ErrnoException | null, written: number, buffer: TBuffer) => void,
|
|
2432
|
+
): void;
|
|
2405
2433
|
/**
|
|
2406
2434
|
* Asynchronously writes `string` to the file referenced by the supplied file descriptor.
|
|
2407
2435
|
* @param fd A file descriptor.
|
|
@@ -2456,6 +2484,22 @@ declare module "fs" {
|
|
|
2456
2484
|
bytesWritten: number;
|
|
2457
2485
|
buffer: TBuffer;
|
|
2458
2486
|
}>;
|
|
2487
|
+
/**
|
|
2488
|
+
* Asynchronously writes `buffer` to the file referenced by the supplied file descriptor.
|
|
2489
|
+
* @param fd A file descriptor.
|
|
2490
|
+
* @param options An object with the following properties:
|
|
2491
|
+
* * `offset` The part of the buffer to be written. If not supplied, defaults to `0`.
|
|
2492
|
+
* * `length` The number of bytes to write. If not supplied, defaults to `buffer.length - offset`.
|
|
2493
|
+
* * `position` The offset from the beginning of the file where this data should be written. If not supplied, defaults to the current position.
|
|
2494
|
+
*/
|
|
2495
|
+
function __promisify__<TBuffer extends NodeJS.ArrayBufferView>(
|
|
2496
|
+
fd: number,
|
|
2497
|
+
buffer?: TBuffer,
|
|
2498
|
+
options?: WriteOptions,
|
|
2499
|
+
): Promise<{
|
|
2500
|
+
bytesWritten: number;
|
|
2501
|
+
buffer: TBuffer;
|
|
2502
|
+
}>;
|
|
2459
2503
|
/**
|
|
2460
2504
|
* Asynchronously writes `string` to the file referenced by the supplied file descriptor.
|
|
2461
2505
|
* @param fd A file descriptor.
|
node v18.19/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "18.19.
|
|
3
|
+
"version": "18.19.95",
|
|
4
4
|
"description": "TypeScript definitions for node",
|
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
|
|
6
6
|
"license": "MIT",
|
|
@@ -220,6 +220,6 @@
|
|
|
220
220
|
"undici-types": "~5.26.4"
|
|
221
221
|
},
|
|
222
222
|
"peerDependencies": {},
|
|
223
|
-
"typesPublisherContentHash": "
|
|
223
|
+
"typesPublisherContentHash": "abefca39201799648b746ba7bba9f40bc520ee46e2675045726a68f3aa8248b1",
|
|
224
224
|
"typeScriptVersion": "5.1"
|
|
225
225
|
}
|