@@ -355,25 +355,6 @@ signal.addEventListener('abort', () => {
355
355
setTimeout (() => ac .abort (), 10000 );
356
356
```
357
357
358
- If this method is invoked as it's util.promisify()ed version, it returns a
359
- Promise that fulfills with the answer. If the question is canceled using
360
- an ` AbortController ` it will reject with an ` AbortError ` .
361
-
362
- ``` js
363
- const util = require (' util' );
364
- const question = util .promisify (rl .question ).bind (rl);
365
-
366
- async function questionExample () {
367
- try {
368
- const answer = await question (' What is you favorite food? ' );
369
- console .log (` Oh, so your favorite food is ${ answer} ` );
370
- } catch (err) {
371
- console .error (' Question rejected' , err);
372
- }
373
- }
374
- questionExample ();
375
- ```
376
-
377
358
### ` rl.resume() `
378
359
379
360
<!-- YAML
@@ -899,25 +880,6 @@ signal.addEventListener('abort', () => {
899
880
setTimeout (() => ac .abort (), 10000 );
900
881
```
901
882
902
- If this method is invoked as it's util.promisify()ed version, it returns a
903
- Promise that fulfills with the answer. If the question is canceled using
904
- an ` AbortController ` it will reject with an ` AbortError ` .
905
-
906
- ``` js
907
- const util = require (' util' );
908
- const question = util .promisify (rl .question ).bind (rl);
909
-
910
- async function questionExample () {
911
- try {
912
- const answer = await question (' What is you favorite food? ' );
913
- console .log (` Oh, so your favorite food is ${ answer} ` );
914
- } catch (err) {
915
- console .error (' Question rejected' , err);
916
- }
917
- }
918
- questionExample ();
919
- ```
920
-
921
883
### ` readline.clearLine(stream, dir[, callback]) `
922
884
923
885
<!-- YAML
0 commit comments