Open powerdong opened 4 years ago
const arr = [{ startTime: "02:00" stopTime: "05:00" }, { startTime: "08:00" stopTime: "10:00" }, { startTime: "18:00" stopTime: "19:00" }, { startTime: "07:00" stopTime: "09:00" }]
需要对startTime排序,
arr1.sort((a, b) => { return a.startTime.localeCompare(b.startTime) })
需要对startTime排序,