Object.assign( target, source )
Rough spec expectations:
- Only enumerable own properties of source
- Invoke [[Get]] on property list derived from source, for each property in list [[Put]] on target
- private names are not copied
- unique names are copied
- super mechanism (rebind super)… AWB To determine needs
- Returns modified "target"
I really feel like if this function doesn’t accept more than one source object argument, people are going to keep writing alternatives for it so it might as well not even be in the spec. Using Array.prototype.reduce just doesn’t cut it when it comes to the sort of expressibility people have come to expect from jQuery.extend, dojo.mixin, etc.