Get unlimited public & private packages + team-based management with npm Teams.Learn more »

just-pick

2.1.0 • Public • Published

just-pick

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 pick from 'just-pick';
 
var obj = { a: 3, b: 5, c: 9 };
pick(obj, ['a', 'c']); // {a: 3, c: 9}
pick(obj, 'a', 'c'); // {a: 3, c: 9}
pick(obj, ['a', 'b', 'd']); // {a: 3, b: 5}
pick(obj, ['a', 'a']); // {a: 3}

Install

npm i just-pick

DownloadsWeekly Downloads

1,745

Version

2.1.0

License

MIT

Unpacked Size

2.51 kB

Total Files

4

Last publish

Collaborators

  • avatar