Package: effect
Module: Schedule
Creates a schedule that recurs at a fixed interval.
Details
This schedule executes at regular, evenly spaced intervals, returning the number of times it has run so far. If the action being executed takes longer than the interval, the next execution will happen immediately to prevent “pile-ups,” ensuring that the schedule remains consistent without overlapping executions.
|-----interval-----|-----interval-----|-----interval-----|
|---------action--------||action|-----|action|-----------|
See
spaced If you need to run from the end of the last execution.Signature
declare const fixed: (interval: Duration.DurationInput) => Schedule<number>
Since v2.0.0