Skip to content
This repository was archived by the owner on Apr 22, 2023. It is now read-only.

explaining where "r" came from #8777

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions doc/api/repl.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,12 @@ to signal "end" on the `input` stream.

Example of listening for `exit`:

var r = repl.start({
prompt: "> ",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use single quote(') to keep coding style consistent in other parts of this markdown imo

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @yorkie are you talking the double-quotes in prompt: "> "? There's another example right above it on the page that uses double-quotes as well. Could we update all of them in another pr?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yorkie I replaced all double-quotes with single quotes here #8778

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that's awesome 👍

input: process.stdin,
output: process.stdout
});

r.on('exit', function () {
console.log('Got "exit" event from repl!');
process.exit();
Expand Down