npm

Don't miss out on this year's npm Pride t-shirt designs!Order your favorites here »

just-map-values

1.1.0 • Public • Published

just-map-object

Part of a library of zero-dependency npm modules that do just do one thing. Guilt-free utilities for every occasion.

Try it now

import map from 'just-map-values';
 
// predicate updates values, recieves (value, key, obj)
map({a: 3, b: 5, c: 9}, (value) => value + 1); // {a: 4, b: 6, c: 10}
map({a: 3, b: 5, c: 9}, (value, key) => value + key); // {a: 3a, b: 5b, c: 9c}
map({a: 3, b: 5, c: 9}, (value, key, obj) => obj.b); // {a: 5, b: 5, c: 5}

install

npm i just-map-values

Downloadsweekly downloads

12,242

version

1.1.0

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability