Skip to content

Commit

Permalink
doc: add socket.readyState
Browse files Browse the repository at this point in the history
+ description of `socket.readyState`

Note: YAML tag found in commit e697cfb

Co-authored-by: Michael Auderer <mike@silverstone.io>

PR-URL: nodejs#35262
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
  • Loading branch information
clarkkozak authored and joesepi committed Oct 22, 2020
1 parent 473feff commit d3d7e03
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions doc/api/net.md
Original file line number Diff line number Diff line change
Expand Up @@ -1028,6 +1028,20 @@ written out, which may not be immediately.
See `Writable` stream [`write()`][stream_writable_write] method for more
information.

### `socket.readyState`
<!-- YAML
added: v0.5.0
-->

* {string}

This property represents the state of the connection as a string.

* If the stream is connecting `socket.readyState` is `opening`.
* If the stream is readable and writable, it is `open`.
* If the stream is readable and not writable, it is `readOnly`.
* If the stream is not readable and writable, it is `writeOnly`.

## `net.connect()`

Aliases to
Expand Down

0 comments on commit d3d7e03

Please sign in to comment.