nod

nodei

Run script, then REPL it with automatically exported globals

Showing:

Popularity

Downloads/wk

0

GitHub Stars

1

Maintenance

Last Commit

7yrs ago

Contributors

0

Package

Dependencies

4

License

MIT

Type Definitions

Tree-Shakeable

No?

Categories

Readme

npm

nodei

Build Status Dependency Status

nodei executes script files and exports global declarations into the REPL.

Supports modules and REPL commands.

Example

foo.js:

var foo = 4;

var printFoo = function () {
  return foo;
};

nodei repl session:

$ nodei foo.js
> foo
4
> printFoo()
4

/* Change foo.js. */

> .reload
> foo
6

Commands

CommandDescription
.reloadReload the active JS file
.load %file%Load %file% into REPL, set it as a target for future .reloads

Yes, built-in .load is gone.

CLI

nodei [<filename>]

API

nodei([filename], [options])

Start the REPL session, populate it with commands and load filename.

options are passed to repl.start and can override defaults.

Return the REPL instance.

Event: 'load(filename)'

Emitted when file is loaded via .load or .reload, or at startup.

Install

npm install nodei -g

License

MIT

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100
No reviews found
Be the first to rate

Alternatives

No alternatives found

Tutorials

No tutorials found
Add a tutorial