@@ -374,7 +374,7 @@ added: v10.0.0
374374 file data read.
375375* ` offset` {integer} The location in the buffer at which to start filling.
376376* ` length` {integer} The number of bytes to read.
377- * ` position` {integer} The location where to begin reading data from the
377+ * ` position` {integer|null } The location where to begin reading data from the
378378 file. If ` null ` , data will be read from the current file position, and
379379 the position will be updated. If ` position` is an integer, the current
380380 file position will remain unchanged.
@@ -403,7 +403,7 @@ added:
403403 **Default:** ` 0 `
404404 * ` length` {integer} The number of bytes to read. **Default:**
405405 ` buffer .byteLength - offset`
406- * ` position` {integer} The location where to begin reading data from the
406+ * ` position` {integer|null } The location where to begin reading data from the
407407 file. If ` null ` , data will be read from the current file position, and
408408 the position will be updated. If ` position` is an integer, the current
409409 file position will remain unchanged. **Default:**: ` null `
@@ -450,9 +450,9 @@ added:
450450-->
451451
452452* ` buffers` {Buffer\[ ]|TypedArray\[ ]|DataView\[ ]}
453- * ` position` {integer} The offset from the beginning of the file where the data
454- should be read from. If ` position` is not a ` number` , the data will be read
455- from the current position.
453+ * ` position` {integer|null } The offset from the beginning of the file where
454+ the data should be read from. If ` position` is not a ` number` , the data will
455+ be read from the current position. **Default:** ` null `
456456* Returns: {Promise} Fulfills upon success an object containing two properties:
457457 * ` bytesRead` {integer} the number of bytes read
458458 * ` buffers` {Buffer\[ ]|TypedArray\[ ]|DataView\[ ]} property containing
@@ -550,10 +550,10 @@ changes:
550550 to write begins. **Default:** ` 0 `
551551* ` length` {integer} The number of bytes from ` buffer` to write. **Default:**
552552 ` buffer .byteLength - offset`
553- * ` position` {integer} The offset from the beginning of the file where the
553+ * ` position` {integer|null } The offset from the beginning of the file where the
554554 data from ` buffer` should be written. If ` position` is not a ` number` ,
555555 the data will be written at the current position. See the POSIX pwrite(2)
556- documentation for more detail.
556+ documentation for more detail. **Default:** ` null `
557557* Returns: {Promise}
558558
559559Write ` buffer` to the file.
@@ -584,10 +584,10 @@ changes:
584584-->
585585
586586* ` string` {string}
587- * ` position` {integer} The offset from the beginning of the file where the
587+ * ` position` {integer|null } The offset from the beginning of the file where the
588588 data from ` string` should be written. If ` position` is not a ` number` the
589589 data will be written at the current position. See the POSIX pwrite(2)
590- documentation for more detail.
590+ documentation for more detail. **Default:** ` null `
591591* ` encoding` {string} The expected string encoding. **Default:** ` ' utf8' `
592592* Returns: {Promise}
593593
@@ -650,9 +650,9 @@ added: v12.9.0
650650-->
651651
652652* ` buffers` {Buffer\[ ]|TypedArray\[ ]|DataView\[ ]}
653- * ` position` {integer} The offset from the beginning of the file where the
653+ * ` position` {integer|null } The offset from the beginning of the file where the
654654 data from ` buffers` should be written. If ` position` is not a ` number` ,
655- the data will be written at the current position.
655+ the data will be written at the current position. **Default:** ` null `
656656* Returns: {Promise}
657657
658658Write an array of {ArrayBufferView}s to the file.
@@ -3009,7 +3009,7 @@ changes:
30093009 written to.
30103010* ` offset` {integer} The position in ` buffer` to write the data to.
30113011* ` length` {integer} The number of bytes to read.
3012- * ` position` {integer|bigint} Specifies where to begin reading from in the
3012+ * ` position` {integer|bigint|null } Specifies where to begin reading from in the
30133013 file. If ` position` is ` null ` or ` - 1 ` , data will be read from the current
30143014 file position, and the file position will be updated. If ` position` is an
30153015 integer, the file position will be unchanged.
@@ -3048,7 +3048,7 @@ changes:
30483048 * ` buffer` {Buffer|TypedArray|DataView} **Default:** ` Buffer .alloc (16384 )`
30493049 * ` offset` {integer} **Default:** ` 0 `
30503050 * ` length` {integer} **Default:** ` buffer .byteLength - offset`
3051- * ` position` {integer|bigint} **Default:** ` null `
3051+ * ` position` {integer|bigint|null } **Default:** ` null `
30523052* ` callback` {Function}
30533053 * ` err` {Error}
30543054 * ` bytesRead` {integer}
@@ -3290,7 +3290,7 @@ added:
32903290
32913291* ` fd` {integer}
32923292* ` buffers` {ArrayBufferView \[]}
3293- * ` position` {integer}
3293+ * ` position` {integer| null } ** Default : ** ` null `
32943294* ` callback` {Function }
32953295 * ` err` {Error }
32963296 * ` bytesRead` {integer}
@@ -3679,7 +3679,7 @@ changes:
36793679
36803680* ` target` {string| Buffer| URL }
36813681* ` path` {string| Buffer| URL }
3682- * ` type` {string}
3682+ * ` type` {string| null } ** Default : ** ` null `
36833683* ` callback` {Function }
36843684 * ` err` {Error }
36853685
@@ -3690,8 +3690,8 @@ See the POSIX symlink(2) documentation for more details.
36903690
36913691The ` type` argument is only available on Windows and ignored on other platforms.
36923692It can be set to ` 'dir'` , ` 'file'` , or ` 'junction'` . If the ` type` argument is
3693- not set , Node .js will autodetect ` target` type and use ` 'file'` or ` 'dir'` . If
3694- the ` target` does not exist, ` 'file'` will be used . Windows junction points
3693+ not a string , Node .js will autodetect ` target` type and use ` 'file'` or ` 'dir'` .
3694+ If the ` target` does not exist, ` 'file'` will be used . Windows junction points
36953695require the destination path to be absolute . When using ` 'junction'` , the
36963696` target` argument will automatically be normalized to absolute path.
36973697
@@ -4096,9 +4096,9 @@ changes:
40964096
40974097* ` fd` {integer}
40984098* ` buffer` {Buffer|TypedArray|DataView}
4099- * ` offset` {integer}
4100- * ` length` {integer}
4101- * ` position` {integer}
4099+ * ` offset` {integer} **Default:** ` 0 `
4100+ * ` length` {integer} **Default:** ` buffer . byteLength - offset `
4101+ * ` position` {integer|null} **Default:** ` null `
41024102* ` callback` {Function}
41034103 * ` err` {Error}
41044104 * ` bytesWritten` {integer}
@@ -4159,7 +4159,7 @@ changes:
41594159
41604160* ` fd` {integer}
41614161* ` string` {string|Object}
4162- * ` position` {integer}
4162+ * ` position` {integer|null} **Default:** ` null `
41634163* ` encoding` {string} **Default:** ` ' utf8' `
41644164* ` callback` {Function}
41654165 * ` err` {Error}
@@ -4348,7 +4348,7 @@ added: v12.9.0
43484348
43494349* ` fd` {integer}
43504350* ` buffers` {ArrayBufferView\[ ]}
4351- * ` position` {integer}
4351+ * ` position` {integer|null} **Default:** ` null `
43524352* ` callback` {Function}
43534353 * ` err` {Error}
43544354 * ` bytesWritten` {integer}
@@ -5061,7 +5061,7 @@ object with an `encoding` property specifying the character encoding to use for
50615061the link path returned. If the ` encoding` is set to ` ' buffer' ` ,
50625062the link path returned will be passed as a {Buffer} object.
50635063
5064- ### ` fs .readSync (fd, buffer, offset, length, position)`
5064+ ### ` fs .readSync (fd, buffer, offset, length[ , position] )`
50655065
50665066<!-- YAML
50675067added: v0.1.21
@@ -5079,7 +5079,7 @@ changes:
50795079* ` buffer` {Buffer|TypedArray|DataView}
50805080* ` offset` {integer}
50815081* ` length` {integer}
5082- * ` position` {integer|bigint}
5082+ * ` position` {integer|bigint|null} **Default:** ` null `
50835083* Returns: {number}
50845084
50855085Returns the number of ` bytesRead` .
@@ -5107,7 +5107,7 @@ changes:
51075107* ` options` {Object}
51085108 * ` offset` {integer} **Default:** ` 0 `
51095109 * ` length` {integer} **Default:** ` buffer .byteLength - offset`
5110- * ` position` {integer|bigint} **Default:** ` null `
5110+ * ` position` {integer|bigint|null } **Default:** ` null `
51115111* Returns: {number}
51125112
51135113Returns the number of ` bytesRead` .
@@ -5128,7 +5128,7 @@ added:
51285128
51295129* ` fd` {integer}
51305130* ` buffers` {ArrayBufferView\[ ]}
5131- * ` position` {integer}
5131+ * ` position` {integer|null} **Default:** ` null `
51325132* Returns: {number} The number of bytes read.
51335133
51345134For detailed information, see the documentation of the asynchronous version of
@@ -5350,7 +5350,7 @@ changes:
53505350
53515351* ` target` {string|Buffer|URL}
53525352* ` path` {string|Buffer|URL}
5353- * ` type` {string}
5353+ * ` type` {string|null} **Default:** ` null `
53545354
53555355Returns ` undefined ` .
53565356
@@ -5482,9 +5482,9 @@ changes:
54825482
54835483* ` fd` {integer}
54845484* ` buffer` {Buffer|TypedArray|DataView}
5485- * ` offset` {integer}
5486- * ` length` {integer}
5487- * ` position` {integer}
5485+ * ` offset` {integer} **Default:** ` 0 `
5486+ * ` length` {integer} **Default:** ` buffer . byteLength - offset `
5487+ * ` position` {integer|null} **Default:** ` null `
54885488* Returns: {number} The number of bytes written.
54895489
54905490For detailed information, see the documentation of the asynchronous version of
@@ -5506,8 +5506,8 @@ changes:
55065506
55075507* ` fd` {integer}
55085508* ` string` {string}
5509- * ` position` {integer}
5510- * ` encoding` {string}
5509+ * ` position` {integer|null} **Default:** ` null `
5510+ * ` encoding` {string} **Default:** ` ' utf8 ' `
55115511* Returns: {number} The number of bytes written.
55125512
55135513For detailed information, see the documentation of the asynchronous version of
@@ -5521,7 +5521,7 @@ added: v12.9.0
55215521
55225522* ` fd` {integer}
55235523* ` buffers` {ArrayBufferView\[ ]}
5524- * ` position` {integer}
5524+ * ` position` {integer|null} **Default:** ` null `
55255525* Returns: {number} The number of bytes written.
55265526
55275527For detailed information, see the documentation of the asynchronous version of
0 commit comments