@types/node 16.4.4 → 16.4.5
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/cluster.d.ts +0 -1
- node/crypto.d.ts +0 -1
- node/fs/promises.d.ts +35 -0
- node/package.json +2 -2
node/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This package contains type definitions for Node.js (http://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: Wed, 28 Jul 2021 07:31:16 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
13
|
* Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`
|
|
14
14
|
|
node/cluster.d.ts
CHANGED
|
@@ -119,7 +119,6 @@ declare module 'cluster' {
|
|
|
119
119
|
send(message: child.Serializable, callback?: (error: Error | null) => void): boolean;
|
|
120
120
|
send(message: child.Serializable, sendHandle: child.SendHandle, callback?: (error: Error | null) => void): boolean;
|
|
121
121
|
send(message: child.Serializable, sendHandle: child.SendHandle, options?: child.MessageOptions, callback?: (error: Error | null) => void): boolean;
|
|
122
|
-
|
|
123
122
|
/**
|
|
124
123
|
* This function will kill the worker. In the primary, it does this
|
|
125
124
|
* by disconnecting the `worker.process`, and once disconnected, killing
|
node/crypto.d.ts
CHANGED
node/fs/promises.d.ts
CHANGED
|
@@ -229,6 +229,41 @@ declare module 'fs/promises' {
|
|
|
229
229
|
* @since v10.0.0
|
|
230
230
|
*/
|
|
231
231
|
writeFile(data: string | Uint8Array, options?: (ObjectEncodingOptions & FlagAndOpenMode & Abortable) | BufferEncoding | null): Promise<void>;
|
|
232
|
+
/**
|
|
233
|
+
* Write `buffer` to the file.
|
|
234
|
+
*
|
|
235
|
+
* The promise is resolved with an object containing two properties:
|
|
236
|
+
*
|
|
237
|
+
* It is unsafe to use `filehandle.write()` multiple times on the same file
|
|
238
|
+
* without waiting for the promise to be resolved (or rejected). For this
|
|
239
|
+
* scenario, use `fs.createWriteStream()`.
|
|
240
|
+
*
|
|
241
|
+
* On Linux, positional writes do not work when the file is opened in append mode.
|
|
242
|
+
* The kernel ignores the position argument and always appends the data to
|
|
243
|
+
* the end of the file.
|
|
244
|
+
* @since v10.0.0
|
|
245
|
+
* @param offset The start position from within `buffer` where the data to write begins.
|
|
246
|
+
* @param length The number of bytes from `buffer` to write.
|
|
247
|
+
* @param position The offset from the beginning of the file where the data from `buffer` should be written. If `position` is not a `number`, the data will be written at the current position.
|
|
248
|
+
* See the POSIX pwrite(2) documentation for more detail.
|
|
249
|
+
*/
|
|
250
|
+
write<TBuffer extends Uint8Array>(
|
|
251
|
+
buffer: TBuffer,
|
|
252
|
+
offset?: number | null,
|
|
253
|
+
length?: number | null,
|
|
254
|
+
position?: number | null
|
|
255
|
+
): Promise<{
|
|
256
|
+
bytesWritten: number;
|
|
257
|
+
buffer: TBuffer;
|
|
258
|
+
}>;
|
|
259
|
+
write(
|
|
260
|
+
data: string,
|
|
261
|
+
position?: number | null,
|
|
262
|
+
encoding?: BufferEncoding | null
|
|
263
|
+
): Promise<{
|
|
264
|
+
bytesWritten: number;
|
|
265
|
+
buffer: string;
|
|
266
|
+
}>;
|
|
232
267
|
/**
|
|
233
268
|
* Write an array of [<ArrayBufferView>](https://developer.mozilla.org/en-US/docs/Web/API/ArrayBufferView)s to the file.
|
|
234
269
|
*
|
node/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "16.4.
|
|
3
|
+
"version": "16.4.5",
|
|
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": "98c66e97322cf8ea4701d26cb699718e44f01a3ac25a1096136e1f082c6c125a",
|
|
236
236
|
"typeScriptVersion": "3.6"
|
|
237
237
|
}
|