I have 2 point objects as below, Please note that
point1 (p1, p2, p3 and p4) are string type but they are decimal point numbers.
point2 (p1, p2, p3 and p4) are numbers.
There are other properties in the objects as well but I don't need to compare equality of them
How can I compare equality for point1 (p1, p2, p3 and p4) === point2 (p1, p2, p3 and p4) only
const point1 = { id: 1234, p1: "1.000000", p2: undefined, p3: "1.0", p4: "1.0", p5: "somevale 1" }; const point2 = { id: 3456, p1: 1, p2: undefined, p3: 1, p4: 1, p5: "somevalue 2" };