search object by property javascript array code example
Example 1: javascript find object in array
myArray.findIndex(x => x.id === '45');
Example 2: js find element in array by property
var result = jsObjects.find(obj => {
return obj.b === 6
})