I have an object containing objects with objects within them. Each object have an ordernum. I want to sort the objects with the lowest ordernum first.
I have used the function bellow when sorting arrays but I need help adjusting it to this structure.
function(a, b) {
return parseFloat(a.ordernum) - parseFloat(b.ordernum);
}