NPM.listPackages()

List packages in the public npm registry whose keywords match the specified search query.

Usage

Hover over inputs/exits for more info.

var NPM = require('machinepack-npm');


// List packages in the public npm registry whose keywords match the specified search query.

NPM.listPackages({

query: 'sails-hook-',

}).exec({

// An unexpected error occurred.

error: function (err) {

 

},

// OK.

success: function (result) {

 

},

});

Inputs

query required

A string that will be used when querying npm.

'sails-hook-'

Exits

error

An unexpected error occurred.

success

OK.

[ 'sails-hook-autoreload' ]