Is there a consistent way to compare two versions of an Obj and determine what, if any, fields have changed?


Given two versions of an object, how can one determine which fields have changed and what the values were in the two versions.


So far, what I’ve found is:

  1. I can use Value.valuesEqual or Value.compareValues to do a deep comparison of the object.

  2. I can use ArryEdit.fromDiff([version1], [version2]) to generate an array of EditLists which contains exactly the differences I wish to see (the FieldEdit provides the name of the field and how it has changed)

Currently, I do not see a method to accomplish 2) from Javascript directly on a single object, so I am adding it now as Value.diff.