delprzemo / object-pick

Returns a filtered copy of an object with only the specified keys, similar to _.pick from lodash / underscore.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

object-pick-ts

Install

Install with npm:

$ npm install --save object-pick-ts

Usage

import {ObjectPick as pick} from "object-pick-ts";
 
let result = pick({a: 'a', b: 'b', c: 2}, ['a', 'c']);

//{a: 'a', c: 2};

About

Related projects object.pick (https://www.npmjs.com/package/object.pick): JS version of this package

Contributing

Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.

Author

Przemek Struciński (delprzemo)

github/delprzemo License Copyright © 2016, Przemek Struciński. Released under the MIT license.

About

Returns a filtered copy of an object with only the specified keys, similar to _.pick from lodash / underscore.


Languages

Language:TypeScript 51.9%Language:JavaScript 48.1%