Merges the properties of the source object into the target object.
You can provide a custom merge
function to control how properties are merged. It should return the value to be set in the target object.
If it returns undefined
, a default deep merge will be applied for arrays and objects:
Note that this function mutates the target object.
The target object into which the source object properties will be merged. This object is modified in place.
The source object whose properties will be merged into the target object.
A custom merge function that defines how properties should be combined. It receives the following arguments:
targetValue
: The current value of the property in the target object.sourceValue
: The value of the property in the source object.key
: The key of the property being merged.target
: The target object.source
: The source object.The updated target object with properties from the source object merged in.
Alias