objmap

map over objects

npm install objmap
7 downloads in the last month

objmap

map over objects

Installation

$ npm install objmap

or

$ component install nathan7/objmap

API

objmap(obj, function(value, key, obj), newObj = {}, thisObj)

Creates a new object with the same keys as obj and the values returned from the callback.

objmap.keys(keys, function(key), newObj = {}, thisObj)

Creates a new object with the given keys and the values returned from the callback.

objmap.toArray(obj, function(value, key, obj), thisObj)

Creates a new array with the values returned from the callback.

License

MIT

npm loves you