@extra-object/reject-at

Gets object without given keys.

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
@extra-object/reject-at
032.2.52 years ago2 years agoMinified + gzip package size for @extra-object/reject-at in KB

Readme

Gets object without given keys. :running: :vhs: :package: :moon: :ledger:
Alternatives: rejectAt, rejectAt$.
Similar: map, reduce, filter, filterAt, reject, rejectAt.
This is part of package extra-object.

object.rejectAt(x, ks);
// x:  an object
// ks: keys

const object = require('extra-object');

var x = {a: 1, b: 2, c: 3, d: 4, e: 5};
object.rejectAt(x, ['a', 'c', 'e']);
// { b: 2, d: 4 }

object.rejectAt(x, ['b', 'd']);
// { a: 1, c: 3, e: 5 }

references