Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

eachMinuteOfInterval

import { eachMinuteOfInterval } from "https://esm.sh/v135/date-fns@3.6.0/index.d.mts";
@example
// Each minute between 14 October 2020, 13:00 and 14 October 2020, 13:03
const result = eachMinuteOfInterval({
  start: new Date(2014, 9, 14, 13),
  end: new Date(2014, 9, 14, 13, 3)
})
//=> [
//   Wed Oct 14 2014 13:00:00,
//   Wed Oct 14 2014 13:01:00,
//   Wed Oct 14 2014 13:02:00,
//   Wed Oct 14 2014 13:03:00
// ]
function eachMinuteOfInterval<DateType extends Date>(interval: Interval<DateType>, options?: EachMinuteOfIntervalOptions): DateType[];
§
eachMinuteOfInterval<DateType extends Date>(interval: Interval<DateType>, options?: EachMinuteOfIntervalOptions): DateType[]
[src]

§Type Parameters

§
DateType extends Date
[src]

§Parameters

§
interval: Interval<DateType>
[src]
  • The interval.
§
  • An object with options.

§Return Type

§
DateType[]
[src]

The array with starts of minutes from the minute of the interval start to the minute of the interval end