Skip to content

Commit

Permalink
doc: document argument variant in the repl.md
Browse files Browse the repository at this point in the history
`options` in the `repl.start([options])` can be a string.

Ref: #10160

PR-URL: #10221
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
  • Loading branch information
vsemozhetbyt authored and italoacasas committed Jan 30, 2017
1 parent 807e99b commit 5250b33
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions doc/api/repl.md
Original file line number Diff line number Diff line change
Expand Up @@ -418,6 +418,15 @@ added: v0.1.91

The `repl.start()` method creates and starts a `repl.REPLServer` instance.

If `options` is a string, then it specifies the input prompt:

```js
const repl = require('repl');

// a Unix style prompt
repl.start('$ ');
```

## The Node.js REPL

Node.js itself uses the `repl` module to provide its own interactive interface
Expand Down

0 comments on commit 5250b33

Please sign in to comment.