Releases: rautio/crontext
Fixes bug with 'every X minutes' not using '*'
Fixes bug with 'every X minutes' not using '*'
Customize the start of day when using non specific schedules like 'Every Monday'
Customize the start of day when using non specific schedules like 'Every Monday'.
New options passed to parseText(cron, options)
where options
is:
{
preset?: 'system';
defaultHour?: string;
defaultMinute?: string;
};
Fixes misc. bugs with date/day ranges not being reset on nextDate()
Fixes misc. bugs with date/day ranges not being reset on nextDate()
Add support for '*/15' syntax in next occurrence
Add support for '*/15' syntax in next occurrence
Fix bug with day tokenization
Fixes a bug where every weekd
would throw an error on the weekd
match with the tokenizer. The 'day' regex was matching on this partial text which occurs when a user is manually typing every weekday
or every weekend
without debouncing the input.
Next occurrence support
Add a new nextDate
function that returns the next occurrence of a given cron schedule as a JS Date object:
import { nextDate } from 'crontext';
const date = nextDate('* * * * * ', new Date());
Warning message
Adds a warning message to the readme
Support for 'every week'
Adds support for 'every week' syntax.
Fix crashing on empty string
Fixes a bug where if you pass in an empty string, the tokenizer will throw an error. Now instead it will return the default "every minute" format.
Initial release
Initial working copy. Still in beta. Not meant for production use.