how to get the highest attribute array of objects in javascript code example
Example 1: filter biggest value javascript object
const max = data.reduce((prev, current) => (prev.y > current.y) ? prev : current)
Example 2: find max of array of objects key
Math.max.apply(Math, array.map(function(o) { return o.y; }))