Would it be possible to add a key definition to the custom sort parameters so that we are able to reuse the sort function for multiple columns? This would be useful for 2+ date columns, for example.
dateSort(a, b, sortOrder, key) {
let date1 = new Date(a[key]);
let date2 = new Date(b[key]);
if (date1 === date2) {
return 0;
}
if (date1 > date2) {
return 1 * sortOrder;
}
return -1 * sortOrder;
}
Would it be possible to add a key definition to the custom sort parameters so that we are able to reuse the sort function for multiple columns? This would be useful for 2+ date columns, for example.