You have a few syntax errors in your code above. data2
is an array of objects so you don't need to do Object.entries() to get the elements of the array. I would use Array.some() method here so that it returns a boolean value instead of the actual data element if you are hoping to have a true or false value logged. the Array.some() method just returns once one case is true and we don't have to go through all the entries in the array of object if we already found a match.
let data1 = [{ x: 6232, y: 10536, type: "data4", dead: 0, uid: 3832864 }];
let data2 = [
{ x: 6352, y: 10656, type: "data1", dead: 0, uid: 3832861 },
{ x: 6322, y: 10546, type: "data2", dead: 0, uid: 3832862 },
{ x: 6542, y: 15356, type: "data3", dead: 0, uid: 3832863 },
{ x: 6232, y: 10536, type: "data4", dead: 0, uid: 3832864 }
];
let check = data2.some(entry => entry.uid == data1[0].uid);
console.log(check); // Expected output to be true.
If you didn't have a unique id for each entry then a quick and dirty way to do this would be to stringify both objects and then compare the strings. This has its limitations because the order of the fields in your object must be the same.
var object = { 'a': 1, 'b':2};
var other = { 'a': 1, 'b':2 };
console.log(JSON.stringify(object) == JSON.stringify(other)); //this will print true
For deep object comparison, I like to use the isequal method from lodash
var object = { 'a': 1, 'b':2};
var other = { 'b':2, 'a': 1 };
console.log(JSON.stringify(object) == JSON.stringify(other)); //this will print false
console.log(_.isEqual(object, other)); //this will print true