From d47e5d022fe882475b93bbdb7fb11b4940cc39ff Mon Sep 17 00:00:00 2001 From: Christopher Hiller Date: Tue, 20 Mar 2018 10:19:57 -0700 Subject: [PATCH] doc: add link & simplify data event (net.Socket) PR-URL: https://github.com/nodejs/node/pull/19487 Reviewed-By: James M Snell Reviewed-By: Trivikram Kamat --- doc/api/net.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/api/net.md b/doc/api/net.md index 489659001ce9b9..4b3897f61cb757 100644 --- a/doc/api/net.md +++ b/doc/api/net.md @@ -419,8 +419,7 @@ added: v0.1.90 * {Buffer} Emitted when data is received. The argument `data` will be a `Buffer` or -`String`. Encoding of data is set by `socket.setEncoding()`. -(See the [Readable Stream][] section for more information.) +`String`. Encoding of data is set by [`socket.setEncoding()`][]. Note that the **data will be lost** if there is no listener when a `Socket` emits a `'data'` event. @@ -746,7 +745,7 @@ added: v0.1.90 * Returns: {net.Socket} The socket itself. Set the encoding for the socket as a [Readable Stream][]. See -[`stream.setEncoding()`][] for more information. +[`readable.setEncoding()`][] for more information. ### socket.setKeepAlive([enable][, initialDelay])