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