flitbit / diff

Javascript utility for calculating deep difference, capturing changes, and applying changes across objects; for nodejs and the browser.
MIT License
3k stars 214 forks source link

Order independent array diff #82

Closed jsfuchs closed 7 years ago

jsfuchs commented 7 years ago

Whoops - didn't mean to open it against your repo (wanted to put it into my forked master :D)

NewOldMax commented 7 years ago

It's very useful feature. Can this be in main package? @flitbit

jsfuchs commented 7 years ago

Sure!

jsfuchs commented 7 years ago

Ah ok I'll work on the conflicts on Monday.

NewOldMax commented 7 years ago

@jsfuchs this can solve #100 , right?

jsfuchs commented 7 years ago

So yes and no -

It will be able to determine if there is a difference between two unordered objects/arrays, but the output of the diff is particularly smart or useful since the sorting doesn't always align "like" terms. There would probably have to be a fair amount of work to make the output a sensible diff.

flitbit commented 7 years ago

I'm checking it out; if it does what it says, I agree.

jsfuchs commented 7 years ago

Wrong branch - I'll reopen

nadezhda commented 7 years ago

Would be very useful to have this feature, exactly facing the case #100 .