@@ -34,7 +34,7 @@ Once this code is invoked, the Node.js application will not terminate until the
34
34
` readline.Interface ` is closed because the interface waits for data to be
35
35
received on the ` input ` stream.
36
36
37
- ## Class: Interface
37
+ ## Class: ` Interface `
38
38
<!-- YAML
39
39
added: v0.1.104
40
40
-->
@@ -47,7 +47,7 @@ single `input` [Readable][] stream and a single `output` [Writable][] stream.
47
47
The ` output ` stream is used to print prompts for user input that arrives on,
48
48
and is read from, the ` input ` stream.
49
49
50
- ### Event: 'close'
50
+ ### Event: ` 'close' `
51
51
<!-- YAML
52
52
added: v0.1.98
53
53
-->
@@ -66,7 +66,7 @@ The listener function is called without passing any arguments.
66
66
The ` readline.Interface ` instance is finished once the ` 'close' ` event is
67
67
emitted.
68
68
69
- ### Event: 'line'
69
+ ### Event: ` 'line' `
70
70
<!-- YAML
71
71
added: v0.1.98
72
72
-->
@@ -84,7 +84,7 @@ rl.on('line', (input) => {
84
84
});
85
85
```
86
86
87
- ### Event: 'pause'
87
+ ### Event: ` 'pause' `
88
88
<!-- YAML
89
89
added: v0.7.5
90
90
-->
@@ -103,7 +103,7 @@ rl.on('pause', () => {
103
103
});
104
104
```
105
105
106
- ### Event: 'resume'
106
+ ### Event: ` 'resume' `
107
107
<!-- YAML
108
108
added: v0.7.5
109
109
-->
@@ -118,7 +118,7 @@ rl.on('resume', () => {
118
118
});
119
119
```
120
120
121
- ### Event: 'SIGCONT'
121
+ ### Event: ` 'SIGCONT' `
122
122
<!-- YAML
123
123
added: v0.7.5
124
124
-->
@@ -141,7 +141,7 @@ rl.on('SIGCONT', () => {
141
141
142
142
The ` 'SIGCONT' ` event is _ not_ supported on Windows.
143
143
144
- ### Event: 'SIGINT'
144
+ ### Event: ` 'SIGINT' `
145
145
<!-- YAML
146
146
added: v0.3.0
147
147
-->
@@ -161,7 +161,7 @@ rl.on('SIGINT', () => {
161
161
});
162
162
```
163
163
164
- ### Event: 'SIGTSTP'
164
+ ### Event: ` 'SIGTSTP' `
165
165
<!-- YAML
166
166
added: v0.7.5
167
167
-->
@@ -189,7 +189,7 @@ rl.on('SIGTSTP', () => {
189
189
190
190
The ` 'SIGTSTP' ` event is _ not_ supported on Windows.
191
191
192
- ### rl.close()
192
+ ### ` rl.close() `
193
193
<!-- YAML
194
194
added: v0.1.98
195
195
-->
@@ -201,7 +201,7 @@ the `'close'` event will be emitted.
201
201
Calling ` rl.close() ` does not immediately stop other events (including ` 'line' ` )
202
202
from being emitted by the ` readline.Interface ` instance.
203
203
204
- ### rl.pause()
204
+ ### ` rl.pause() `
205
205
<!-- YAML
206
206
added: v0.3.4
207
207
-->
@@ -212,7 +212,7 @@ later if necessary.
212
212
Calling ` rl.pause() ` does not immediately pause other events (including
213
213
` 'line' ` ) from being emitted by the ` readline.Interface ` instance.
214
214
215
- ### rl.prompt(\ [ preserveCursor\] )
215
+ ### ` rl.prompt([preserveCursor]) `
216
216
<!-- YAML
217
217
added: v0.1.98
218
218
-->
@@ -230,7 +230,7 @@ paused.
230
230
If the ` readline.Interface ` was created with ` output ` set to ` null ` or
231
231
` undefined ` the prompt is not written.
232
232
233
- ### rl.question(query, callback)
233
+ ### ` rl.question(query, callback) `
234
234
<!-- YAML
235
235
added: v0.3.3
236
236
-->
@@ -262,14 +262,14 @@ The `callback` function passed to `rl.question()` does not follow the typical
262
262
pattern of accepting an ` Error ` object or ` null ` as the first argument.
263
263
The ` callback ` is called with the provided answer as the only argument.
264
264
265
- ### rl.resume()
265
+ ### ` rl.resume() `
266
266
<!-- YAML
267
267
added: v0.3.4
268
268
-->
269
269
270
270
The ` rl.resume() ` method resumes the ` input ` stream if it has been paused.
271
271
272
- ### rl.setPrompt(prompt)
272
+ ### ` rl.setPrompt(prompt) `
273
273
<!-- YAML
274
274
added: v0.1.98
275
275
-->
@@ -279,7 +279,7 @@ added: v0.1.98
279
279
The ` rl.setPrompt() ` method sets the prompt that will be written to ` output `
280
280
whenever ` rl.prompt() ` is called.
281
281
282
- ### rl.write(data\ [ , key\] )
282
+ ### ` rl.write(data[, key]) `
283
283
<!-- YAML
284
284
added: v0.1.98
285
285
-->
@@ -312,7 +312,7 @@ rl.write(null, { ctrl: true, name: 'u' });
312
312
The ` rl.write() ` method will write the data to the ` readline ` ` Interface ` 's
313
313
` input ` * as if it were provided by the user* .
314
314
315
- ### rl \ [ Symbol.asyncIterator\ ] ()
315
+ ### ` rl [Symbol.asyncIterator]()`
316
316
<!-- YAML
317
317
added: v11.4.0
318
318
changes:
@@ -349,7 +349,7 @@ async function processLineByLine() {
349
349
}
350
350
```
351
351
352
- ### rl.line
352
+ ### ` rl.line `
353
353
<!-- YAML
354
354
added: 0.1.98
355
355
-->
@@ -384,7 +384,7 @@ process.stdin.on('keypress', (c, k) => {
384
384
});
385
385
```
386
386
387
- ### rl.cursor
387
+ ### ` rl.cursor `
388
388
<!-- YAML
389
389
added: 0.1.98
390
390
-->
@@ -398,7 +398,7 @@ reading input from a TTY stream. The position of cursor determines the
398
398
portion of the input string that will be modified as input is processed,
399
399
as well as the column where the terminal caret will be rendered.
400
400
401
- ### rl.getCursorPos()
401
+ ### ` rl.getCursorPos() `
402
402
<!-- YAML
403
403
added: v13.5.0
404
404
-->
@@ -411,7 +411,7 @@ Returns the real position of the cursor in relation to the input
411
411
prompt + string. Long input (wrapping) strings, as well as multiple
412
412
line prompts are included in the calculations.
413
413
414
- ## readline.clearLine(stream, dir\ [ , callback\] )
414
+ ## ` readline.clearLine(stream, dir[, callback]) `
415
415
<!-- YAML
416
416
added: v0.7.7
417
417
changes:
@@ -433,7 +433,7 @@ changes:
433
433
The ` readline.clearLine() ` method clears current line of given [ TTY] [ ] stream
434
434
in a specified direction identified by ` dir ` .
435
435
436
- ## readline.clearScreenDown(stream\ [ , callback\] )
436
+ ## ` readline.clearScreenDown(stream[, callback]) `
437
437
<!-- YAML
438
438
added: v0.7.7
439
439
changes:
@@ -451,7 +451,7 @@ changes:
451
451
The ` readline.clearScreenDown() ` method clears the given [ TTY] [ ] stream from
452
452
the current position of the cursor down.
453
453
454
- ## readline.createInterface(options)
454
+ ## ` readline.createInterface(options) `
455
455
<!-- YAML
456
456
added: v0.1.98
457
457
changes:
@@ -552,7 +552,7 @@ function completer(linePartial, callback) {
552
552
}
553
553
```
554
554
555
- ## readline.cursorTo(stream, x\ [ , y\]\ [ , callback\] )
555
+ ## ` readline.cursorTo(stream, x[, y] [, callback]) `
556
556
<!-- YAML
557
557
added: v0.7.7
558
558
changes:
@@ -572,7 +572,7 @@ changes:
572
572
The ` readline.cursorTo() ` method moves cursor to the specified position in a
573
573
given [ TTY] [ ] ` stream ` .
574
574
575
- ## readline.emitKeypressEvents(stream\ [ , interface\] )
575
+ ## ` readline.emitKeypressEvents(stream[, interface]) `
576
576
<!-- YAML
577
577
added: v0.7.7
578
578
-->
@@ -598,7 +598,7 @@ if (process.stdin.isTTY)
598
598
process .stdin .setRawMode (true );
599
599
```
600
600
601
- ## readline.moveCursor(stream, dx, dy\ [ , callback\] )
601
+ ## ` readline.moveCursor(stream, dx, dy[, callback]) `
602
602
<!-- YAML
603
603
added: v0.7.7
604
604
changes:
0 commit comments