0.1.0 • Published 11 years ago
sak-getpackage v0.1.0
Sak-getpackage
Version 0.1.0
Get and parse the package.json asynchronously.
Created by Thomas de Zeeuw, thomasdezeeuw@gmail.com (https://thomasdezeeuw.nl/).
Released under a MIT license.
Exports
getPackage
Function
Get a package asynchronously.
Example
getPackage(function (err, pkg) {
if (err) throw err;
console.log('package', pkg); // the package.json object
});
Params
Name | Description | Type | Optional |
---|---|---|---|
path | A path to the package.json | String | Yes |
cb | Callback function | Function |
Return
Description | Type |
---|---|
Package.json object. | Object |