Files
grungnet/src/helpers/diff.js
Mitchell McCaffrey fa1f6fe18f Converted draw actions storage to collapsed representation
Moved to command pattern for action application
2021-02-04 09:11:27 +11:00

16 lines
358 B
JavaScript

import { applyChange, revertChange, diff as deepDiff } from "deep-diff";
export function applyChanges(target, changes) {
for (let change of changes) {
applyChange(target, true, change);
}
}
export function revertChanges(target, changes) {
for (let change of changes) {
revertChange(target, true, change);
}
}
export const diff = deepDiff;