Open sergibondarenko opened 6 years ago
Looks like you've accepted an answer over at StackOverflow, but in case anyone else is reading this, I use moment.js with the fromNow()
function to show, in a human readable form, how long until the next occurrence:
next = later.schedule(mySchedule).next()
timeLeft = moment(next).fromNow()
console.log(timeLeft) // 'in 20 minutes'
How to display what time is left after the later.js text parser applied?
For example, I want to know it before the
setInterval
started.StackOverflow question.