A javascript library for defining recurring schedules and calculating future (or past) occurrences for them. Includes support for using English phrases and Cron schedules. Works in Node and in the browser.
later.date.UTC();
var s = later.parse.text('at 1:15 am on tues, thur every 1st week');
console.log('s', s);
var newEvents = later
.schedule(s)
.next(
100,
new Date('Wed Feb 22 2017 00:00:00 GMT-0600'),
new Date('Wed Apr 25 2017 00:00:00 GMT-0600')
);
for (var i = 0; i < newEvents.length; i++) {
console.log('newEvents[i]', newEvents[i]);
}
The first two events are on Monday and Wednesday rather than Tuesday and Thursday
newEvents[i] Wed Feb 22 2017 19:15:00 GMT-0600 (CST)
newEvents[i] Mon Feb 27 2017 19:15:00 GMT-0600 (CST)
How would I get repeating events that I want to be at 7:15pm Tues and Thurs? I have to use UTC time because it's on a server.
Here is an example
The first two events are on Monday and Wednesday rather than Tuesday and Thursday
newEvents[i] Wed Feb 22 2017 19:15:00 GMT-0600 (CST) newEvents[i] Mon Feb 27 2017 19:15:00 GMT-0600 (CST)
How would I get repeating events that I want to be at 7:15pm Tues and Thurs? I have to use UTC time because it's on a server.