Skip to content

Giancarl021/auto-reload-repl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

auto-reload-repl

Auto Reloads REPL if target folder is changed

Installation (Global/CLI)

npm:

npm install --global auto-reload-repl

Yarn:

yarn global add auto-reload-repl

Usage

API

const repl = require('auto-reload-repl');

repl({
    target: 'path/to/module', // Required
    moduleName: 'myModule', // Optional, default: "m"
    input: process.stdin, // Optional, default: process.stdin
    output: process.stdout // Optional, default: process.stdout
}).catch(console.error);

Parameters:

  • target: The path to the module to be loaded;
  • moduleName: The variable name used in the global context;
  • input: The input stream;
  • output: The output stream.

CLI

repl-ar <target> [-m|--module-name <moduleName>]

Arguments:

  • target: Required, the path to the module to be loaded.

Flags:

  • -m or --module-name: Optional, the variable name used in the global context.

About

Auto Reloads REPL if target folder is changed

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published