Answers for "compare two dates and sort array of objects"

0

compare two dates and sort array of objects

your_array.sort ( (a, b) => {
      return new Date(a.DateTime) - new Date(b.DateTime);
});
Posted by: Guest on March-30-2021

Code answers related to "compare two dates and sort array of objects"

Browse Popular Code Answers by Language