Function: applySnapshot()
function applySnapshot<T>(node, snapshot): void;
Applies a full snapshot over an object, reconciling it with the current contents of the object. If it throws, the changes it made are rolled back (errors thrown by listeners do not roll them back).
Type Parameters
| Type Parameter | Description |
|---|---|
T extends object | Object type. |
Parameters
| Parameter | Type | Description |
|---|---|---|
node | T | Target object (model object, object or array). |
snapshot | | SnapshotInOf<T> | SnapshotOutOf<T> | Snapshot to apply. |
Returns
void