For mapping objects.
objMap({a: 1, b: 2}, function(k, v) {
return k == 'b' ? v * 2 : v;
}); //⇒ {a: 1, b: 4}
objMap.async({a: 1, b: 2}, function(k, v, cb) {
cb(null, k == 'b' ? v * 2 : v);
}, console.log); //⇒ {a: 1, b: 4}
Takes an object and a transformation function and does what you expect.
Takes an object and an asynchronous transformation function and does what you expect.
MIT