MaxBeauchemin
2/4/2020 - 6:15 PM

JavaScript Sort

function compare(a,b) {
  if (a.property < b.property)
    return -1;
  if (a.property > b.property)
    return 1;
  return 0;
}

objs.sort(compare);