let endTime = "23:07";
let startTime = "22:07"
moment.js
?var diff = moment("23:07").unix() - moment("22:07").unix();
moment.utc(moment.duration(diff).asMilliseconds()).format("HH:mm:ss.SSS");
moment.utc(moment.duration(endTime) - moment.duration(startTime)).format('HH:mm')