can-reflect
Advanced tools
Comparing version 1.17.3 to 1.17.4
{ | ||
"name": "can-reflect", | ||
"version": "1.17.3", | ||
"version": "1.17.4", | ||
"description": "reflection on unknown data types", | ||
@@ -5,0 +5,0 @@ "homepage": "http://canjs.com", |
@@ -915,3 +915,4 @@ "use strict"; | ||
* | ||
* Updates the values (and properties if map-like) of `target` to match the values of `source`. This does | ||
* Updates the values (and properties if map-like) of `target` to match the values of `source`. | ||
* Properties of `target` that are not on `source` will be removed. This does | ||
* not recursively update. For that, use [can-reflect.updateDeep]. | ||
@@ -924,3 +925,3 @@ * | ||
* var source = {name: {last: "Meyer"}}; | ||
* var restult = canReflect.assignDeep(target, source); | ||
* var result = canReflect.update(target, source); | ||
* target //-> {name: {last: "Meyer"}} | ||
@@ -934,3 +935,3 @@ * ``` | ||
* var source = ["A","B"]; | ||
* canReflect.assign(target, source); | ||
* canReflect.update(target, source); | ||
* target //-> ["A","B"] | ||
@@ -994,2 +995,3 @@ * ``` | ||
* Updates the values (and properties if map-like) of `target` to match the values of `source`. | ||
* Removes properties from `target` that are not on `source`. | ||
* | ||
@@ -1001,7 +1003,7 @@ * For map-like objects, every enumerable property on `target` is copied: | ||
* var source = {name: {last: "Meyer"}}; | ||
* var restult = canReflect.assignDeep(target, source); | ||
* var result = canReflect.updateDeep(target, source); | ||
* target //-> {name: {last: "Meyer"}} | ||
* ``` | ||
* | ||
* An object can control the behavior of `assignDeep` using the [can-symbol/symbols/updateDeep] symbol. | ||
* An object can control the behavior of `updateDeep` using the [can-symbol/symbols/updateDeep] symbol. | ||
* | ||
@@ -1008,0 +1010,0 @@ * For list-like objects, a diff and patch strategy is used. This attempts to limit the number of changes. |
179102
4865