Skip to main content
Version: next

Type Alias: DateRange

DateRange = { from: Date | undefined; to?: Date; }

Defined in: src/types/shared.ts:202

A range of dates. Unlike DateInterval, the range ends are included.

Example

// Match days between February 2 and February 5, 2019
const matcher: DateRange = {
from: new Date(2019, 1, 2),
to: new Date(2019, 1, 5),
};

Properties

from

from: Date | undefined

Defined in: src/types/shared.ts:202


to?

optional to: Date

Defined in: src/types/shared.ts:202