Copy enumerable properties of source to target object.
Using component
$ component install yiwn/merge
Using npm for browserify
$ npm install yiwn-merge
Example:
var merge = require('yiwn-merge');
var obj1, obj2;
obj1 = { a: 1, b: null };
obj2 = { c: 3, b: 2 };
merge(obj1, obj2); // -> { a: 1, b: null, c: 3 }
merge(obj1, obj2, true); // -> { a: 1, b: 2, c: 3 }
Run tests with mocha
$ make test
The MIT License