I have a tree-structure where I want to use undo/redo. Every leaf in the tree is shown by a directive, at runtime (when the directive starts), I assign a non-enumerable property to the leaf that points to its parent in the tree.
I use Object.defineProperty and set it to enumerable: false. All is good until I try to undo something in the tree and all the hidden attributes disappear from all the leaves.
If I define it as a non-hidden property, angular goes crazy with RangeError: Maximum call stack size exceeded.
Is there a way to work around this and have non-enumerable properties in objects watched by chronicle?
Thanks!
I have a tree-structure where I want to use undo/redo. Every leaf in the tree is shown by a directive, at runtime (when the directive starts), I assign a non-enumerable property to the leaf that points to its parent in the tree.
I use
Object.definePropertyand set it toenumerable: false. All is good until I try to undo something in the tree and all the hidden attributes disappear from all the leaves.If I define it as a non-hidden property, angular goes crazy with
RangeError: Maximum call stack size exceeded.Is there a way to work around this and have non-enumerable properties in objects watched by chronicle?
Thanks!