see #242
// todo: we could compare objects & arrays for equality
if (Neo.isObject(value) || Array.isArray(value) || value !== oldValue) {
The current approach will trigger a change event for each object / array, not checking if the content did change.
The reason was mostly that this logic is inside the Neo.mjs file itself.
The logic for working with non primitive types is e.g. here:
src/util/Array.mjs
src/util/Object.mjs
Obviously, we can not import those files into the very core file of the framework, but we can create shortcuts into the Neo namespace and assume that these util (core) files are always included. @ExtAnimal: Thoughts?
What we need is something like isDeeplyStrict() inside Siesta => a method which can check structures containing nested objects / arrays for equality.
This one should be mapped into the Neo namespace => Neo.isEqual()
see #242
// todo: we could compare objects & arrays for equality if (Neo.isObject(value) || Array.isArray(value) || value !== oldValue) {The current approach will trigger a change event for each object / array, not checking if the content did change.
The reason was mostly that this logic is inside the Neo.mjs file itself.
The logic for working with non primitive types is e.g. here:
Obviously, we can not import those files into the very core file of the framework, but we can create shortcuts into the Neo namespace and assume that these util (core) files are always included. @ExtAnimal: Thoughts?
What we need is something like
isDeeplyStrict()inside Siesta => a method which can check structures containing nested objects / arrays for equality.This one should be mapped into the Neo namespace =>
Neo.isEqual()