@@ -12,9 +12,9 @@ However, it can be accessed using:
1212const tty = require (' tty' );
1313```
1414
15- When Node.js detects that it is being run inside a text terminal ("TTY")
16- context, the ` process.stdin ` will, by default, be initialized as an instance of
17- ` tty.ReadStream ` and both ` process.stdout ` and ` process.stderr ` will, by
15+ When Node.js detects that it is being run with a text terminal ("TTY")
16+ attached, [ ` process.stdin ` ] [ ] will, by default, be initialized as an instance of
17+ ` tty.ReadStream ` and both [ ` process.stdout ` ] [ ] and [ ` process.stderr ` ] [ ] will, by
1818default be instances of ` tty.WriteStream ` . The preferred method of determining
1919whether Node.js is being run within a TTY context is to check that the value of
2020the ` process.stdout.isTTY ` property is ` true ` :
@@ -27,15 +27,16 @@ false
2727```
2828
2929In most cases, there should be little to no reason for an application to
30- create instances of the ` tty.ReadStream ` and ` tty.WriteStream ` classes.
30+ manually create instances of the ` tty.ReadStream ` and ` tty.WriteStream `
31+ classes.
3132
3233## Class: tty.ReadStream
3334<!-- YAML
3435added: v0.5.8
3536-->
3637
37- The ` tty.ReadStream ` class is a subclass of ` net.Socket ` that represents the
38- readable side of a TTY. In normal circumstances ` process.stdin ` will be the
38+ The ` tty.ReadStream ` class is a subclass of [ ` net.Socket ` ] [ ] that represents the
39+ readable side of a TTY. In normal circumstances [ ` process.stdin ` ] [ ] will be the
3940only ` tty.ReadStream ` instance in a Node.js process and there should be no
4041reason to create additional instances.
4142
@@ -52,7 +53,7 @@ raw device. Defaults to `false`.
5253added: v0.5.8
5354-->
5455
55- A ` boolean ` that is always ` true ` .
56+ A ` boolean ` that is always ` true ` for ` tty.ReadStream ` instances .
5657
5758### readStream.setRawMode(mode)
5859<!-- YAML
@@ -77,8 +78,8 @@ added: v0.5.8
7778-->
7879
7980The ` tty.WriteStream ` class is a subclass of ` net.Socket ` that represents the
80- writable side of a TTY. In normal circumstances, ` process.stdout ` and
81- ` process.stderr ` will be the only ` tty.WriteStream ` instances created for a
81+ writable side of a TTY. In normal circumstances, [ ` process.stdout ` ] [ ] and
82+ [ ` process.stderr ` ] [ ] will be the only ` tty.WriteStream ` instances created for a
8283Node.js process and there should be no reason to create additional instances.
8384
8485### Event: 'resize'
@@ -130,3 +131,8 @@ added: v0.5.8
130131The ` tty.isatty() ` method returns ` true ` if the given ` fd ` is associated with
131132a TTY and ` false ` if it is not, including whenever ` fd ` is not a non-negative
132133integer.
134+
135+ [ `net.Socket` ] : net.html#net_class_net_socket
136+ [ `process.stdin` ] : process.html#process_process_stdin
137+ [ `process.stdout` ] : process.html#process_process_stdout
138+ [ `process.stderr` ] : process.html#process_process_stderr
0 commit comments