1.0.5 • Published 8 years ago
assign-defined v1.0.5
assign-defined
Object.assign that skips any undefined properties from source objects
Install
$ npm i assign-defined --save
Usage
var assignDefined = require('assign-defined')
var target = {}
//only copy defined properties
assignDefined(target, { a: undefined, b: 1 }, { c: 2 })
//target is { b: 1, c: 2 }