I would like to see if 2 arrays of objects are exactly the same as one another in terms of array length, object properties, and object values. If not, i would like to return false. These objects are not direct clones. However, they always have the same properties, but their values can change. I will be performing this check every 45 seconds to check for changes.
My example:
var obj1 = [{
id: "1234567",
first_name: "",
last_name: "",
email: "[email protected]",
company: null,
notes: null,
registrationType: "",
alerts: [ ],
reg_scan: null
},
{
id: "1234567",
first_name: "",
last_name: "",
email: "[email protected]",
company: null,
notes: null,
registrationType: "",
alerts: [ ],
reg_scan: null
},
];
var obj2 = [{
id: "1234567",
first_name: "",
last_name: "",
email: "[email protected]",
company: null,
notes: null,
registrationType: "",
alerts: [ ],
reg_scan: null
}];
In my case, I want obj1 === obj2 to return false because even though they have the same properties and values, the array length is different.