New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

replem

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

replem

Instantly try npm modules in REPL environment

  • 2.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

repl'em npm version

Instantly try npm modules in REPL environment.

features

  • Install modules from npm, optionally at specific version.
  • Install modules directly from GitHub at particular commit or branch.
  • Use a custom REPL like coffee-script/repl.
  • Retains history of past sessions.

install

$ npm install -g replem

usage

replem [options] [<pkg>[:<alias>]]...

        --repl     require a custom repl
    -v, --verbose  enable verbose output
    -h, --help     displays help

Launches a REPL session with specified packages installed and available in the context.

arguments

Uses npm install internally, so similar types of arguments are accepted.

For example:

  • Install a specific version: replem lodash@3.0.0
  • Install a module from GitHub: replem githubname/reponame#commit

By postfixing module's name with :<alias> you can set an alias for a module. Module's exports will be available under this name.

$ replem ramda:R
Installed into REPL context:
 - ramda@0.17.1 as R
> R.inc(1) // 2

With a bang (!) after everything, all module's properties will be directly available in context:

$ replem ramda!
Installed into REPL context:
 - ramda@0.17.1 as ramda
> reduce === ramda.reduce
true

custom repl

To use a custom repl, install it to ~/.replem/node_modules first:

$ npm install --prefix ~/.replem coffee-script
$ replem --repl coffee-script/repl lodash
> (n * 2 for n in [0..5])
Array [ 0, 2, 4, 6, 8, 10 ]

requiring from inside installed modules

The REPL context is provided with the function replem.require() that can be used to require from under ~/.replem/node_modules.

caveats

  • Multiple versions of the same module cannot be used concurrently.

Keywords

FAQs

Package last updated on 09 Mar 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc