All Projects → npm → Npm Remote Ls

npm / Npm Remote Ls

Licence: isc
Examine a package's dependency graph before you install it

Programming Languages

javascript
184084 projects - #8 most used programming language

npm-remote-ls

Build Status Coverage Status NPM version Standard Version

Examine a package's dependency graph before you install it.

Installation

npm install npm-remote-ls -g

Usage

Listing Package Dependencies

npm-remote-ls [email protected]

└─ [email protected]
   ├─ [email protected]
   │  ├─ [email protected]
   │  ├─ [email protected]
   │  ├─ [email protected]
   │  └─ [email protected]
   └─ [email protected]

Help!

There are various command line flags you can toggle for npm-remote-ls, for details run:

npm-remote-ls --help

API

Return dependency graph for latest version:

var ls = require('npm-remote-ls').ls;

ls('grunt', 'latest', function(obj) {
  console.log(obj);
});

Return dependency graph for specific version:

var ls = require('npm-remote-ls').ls;

ls('grunt', '0.1.0', function(obj) {
  console.log(obj);
});

Return a flattened list of dependencies:

var ls = require('npm-remote-ls').ls;

ls('grunt', '0.1.0', true, function(obj) {
  console.log(obj);
});

Configure to only return production dependencies:

var ls = require('npm-remote-ls').ls
var config = require('npm-remote-ls').config

config({
  development: false,
  optional: false
})

ls('yargs', 'latest', true, function (obj) {
  console.log(obj)
})

Configure to return peer dependencies:

var ls = require('npm-remote-ls').ls
var config = require('npm-remote-ls').config

config({
  development: true,
  peer: true
})

ls('grunt-contrib-coffee', 'latest', true, function (obj) {
  console.log(obj)
})

License

ISC

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].