@@ -3110,6 +3110,22 @@ releases.
31103110Use [ ` process.getActiveResourcesInfo() ` ] [ ] to get a list of types of active
31113111resources and not the actual references.
31123112
3113+ ### DEP0162: ` fs.write() ` , ` fs.writeFileSync() ` coercion to string
3114+
3115+ <!-- YAML
3116+ changes:
3117+ - version: REPLACEME
3118+ pr-url: https://github.com/nodejs/node/pull/42149
3119+ description: Documentation-only deprecation.
3120+ -->
3121+
3122+ Type: Documentation-only
3123+
3124+ Implicit coercion of objects with own ` toString ` property, passed as second
3125+ parameter in [ ` fs.write() ` ] [ ] , [ ` fs.writeFile() ` ] [ ] , [ ` fs.appendFile() ` ] [ ] ,
3126+ [ ` fs.writeFileSync() ` ] [ ] , and [ ` fs.appendFileSync() ` ] [ ] is deprecated.
3127+ Convert them to primitive strings.
3128+
31133129[ Legacy URL API ] : url.md#legacy-url-api
31143130[ NIST SP 800-38D ] : https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-38d.pdf
31153131[ RFC 6066 ] : https://tools.ietf.org/html/rfc6066#section-3
@@ -3158,6 +3174,8 @@ resources and not the actual references.
31583174[ `events.listenerCount(emitter, eventName)` ] : events.md#eventslistenercountemitter-eventname
31593175[ `fs.FileHandle` ] : fs.md#class-filehandle
31603176[ `fs.access()` ] : fs.md#fsaccesspath-mode-callback
3177+ [ `fs.appendFile()` ] : fs.md#fsappendfilepath-data-options-callback
3178+ [ `fs.appendFileSync()` ] : fs.md#fsappendfilesyncpath-data-options
31613179[ `fs.createReadStream()` ] : fs.md#fscreatereadstreampath-options
31623180[ `fs.createWriteStream()` ] : fs.md#fscreatewritestreampath-options
31633181[ `fs.exists(path, callback)` ] : fs.md#fsexistspath-callback
@@ -3168,6 +3186,9 @@ resources and not the actual references.
31683186[ `fs.read()` ] : fs.md#fsreadfd-buffer-offset-length-position-callback
31693187[ `fs.readSync()` ] : fs.md#fsreadsyncfd-buffer-offset-length-position
31703188[ `fs.stat()` ] : fs.md#fsstatpath-options-callback
3189+ [ `fs.write()` ] : fs.md#fswritefd-buffer-offset-length-position-callback
3190+ [ `fs.writeFile()` ] : fs.md#fswritefilefile-data-options-callback
3191+ [ `fs.writeFileSync()` ] : fs.md#fswritefilesyncfile-data-options
31713192[ `http.ClientRequest` ] : http.md#class-httpclientrequest
31723193[ `http.IncomingMessage` ] : http.md#class-httpincomingmessage
31733194[ `http.ServerResponse` ] : http.md#class-httpserverresponse
0 commit comments