Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

isEqualProps should compare plain JS objects too #129

Open
reverofevil opened this issue Jan 25, 2016 · 1 comment
Open

isEqualProps should compare plain JS objects too #129

reverofevil opened this issue Jan 25, 2016 · 1 comment

Comments

@reverofevil
Copy link

I have a huge array that I would like to put into a structure and get swap event when the whole array gets swapped. Because of a size of that array I'm no fan of converting it into an immutable data structure. Yet when an array gets swapped, omniscient's isEqualProps method checks only if it was a change of a cursor or a change in immutable data structure, totally disregarding the fact an array has been changed. Is such behaviour considered a bug?

@mikaelbr
Copy link
Member

AFAIK, isEqualProps should check nested deep value check. See the documentation for lodash.isequal. But I'm not sure how it handles swapping in a large nested vanilla object in regards to keys. This might be a bug, tho, as I've never encountered this use case before. But it should support it, but I don't know how the key diff in the swap event should be handled.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants