Skip to content
Closed
Changes from 1 commit
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
Prev Previous commit
doc: add replServer.setupHistory() to documentation
  • Loading branch information
lance committed Feb 8, 2019
commit 3352e6e04dd558d4858b8042663df7fc7c425d95
16 changes: 16 additions & 0 deletions doc/api/repl.md
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,22 @@ deprecated: v9.0.0
An internal method used to parse and execute `REPLServer` keywords.
Returns `true` if `keyword` is a valid keyword, otherwise `false`.

### replServer.setupHistory(historyPath, callback)
Comment thread
lance marked this conversation as resolved.
Outdated
<!-- YAML
added: REPLACEME
-->

* `historyPath` {string} the path to the history file
* `callback` {Function} called when history writes are ready or upon error
* `err` {Error}
* `repl` {repl.REPLServer}

Initializes a history log file for the REPL instance. When executing the
Node.js binary and using the command line REPL, a history file is initialized
by default. However, this is not the case when creating a REPL
programmatically. Use this method to initialize a history log file when working
with REPL instances programmatically.

## repl.start([options])
<!-- YAML
added: v0.1.91
Expand Down