@@ -613,6 +613,9 @@ exist. `data` can be a string or a {Buffer}.
613613
614614If ` options` is a string, then it specifies the ` encoding` .
615615
616+ The ` mode` option only affects the newly created file. See [` fs .open ()` ][]
617+ for more details.
618+
616619The ` path` may be specified as a {FileHandle} that has been opened
617620for appending (using ` fsPromises .open ()` ).
618621
@@ -1283,6 +1286,9 @@ The `encoding` option is ignored if `data` is a buffer.
12831286
12841287If `options` is a string, then it specifies the encoding.
12851288
1289+ The `mode` option only affects the newly created file. See [`fs.open()`][]
1290+ for more details.
1291+
12861292Any specified {FileHandle} has to support writing.
12871293
12881294It is unsafe to use `fsPromises.writeFile()` multiple times on the same file
@@ -1548,6 +1554,9 @@ changes:
15481554Asynchronously append data to a file, creating the file if it does not yet
15491555exist. `data` can be a string or a {Buffer}.
15501556
1557+ The `mode` option only affects the newly created file. See [`fs.open()`][]
1558+ for more details.
1559+
15511560```mjs
15521561import { appendFile } from 'fs';
15531562
@@ -3915,6 +3924,9 @@ a file descriptor.
39153924
39163925The ` encoding` option is ignored if ` data` is a buffer.
39173926
3927+ The ` mode` option only affects the newly created file. See [` fs .open ()` ][]
3928+ for more details.
3929+
39183930If ` data` is a plain object, it must have an own (not inherited) ` toString`
39193931function property.
39203932
@@ -4086,6 +4098,9 @@ changes:
40864098Synchronously append data to a file, creating the file if it does not yet
40874099exist. ` data` can be a string or a {Buffer}.
40884100
4101+ The ` mode` option only affects the newly created file. See [` fs .open ()` ][]
4102+ for more details.
4103+
40894104` ` ` mjs
40904105import { appendFileSync } from ' fs' ;
40914106
@@ -4999,6 +5014,9 @@ Returns `undefined`.
49995014If ` data` is a plain object, it must have an own (not inherited) ` toString`
50005015function property.
50015016
5017+ The ` mode` option only affects the newly created file. See [` fs .open ()` ][]
5018+ for more details.
5019+
50025020For detailed information, see the documentation of the asynchronous version of
50035021this API: [` fs .writeFile ()` ][].
50045022
0 commit comments