select-keys-js
Select values from an object. Inspired by GraphQL.
Usage
const select = // Simple Exampleconst obj = a: 1 b: 2 const query = // returns a: 1 b: 2 c: undefined // Nested Objectconst obj = a: 1 b: c: 2 d: e: 4 f: 5 e: 6 f: 7const query = // returns a: 1 b: c: 2 x: undefined d: e: 4 e: 6
Available options
const query = // Exampleconst obj = a: 1 const query = // returns a: 1 b: c: undefined d: undefined const query = // returns a: 1
License
MIT