angular.equals for JSON Object Comparison
TIL that angular has an “equals” method that does a deep comparison between objects to determine equality.
Example:
I needed to do a deep compare between two JSON objects to see if they contained equivalent values, and was about to write my own deep compare when I stumbled upon this built-in. Way to go angular!
Comments