initialDateRange property Null safety

DateTimeRange? initialDateRange

The date range that the date range picker starts with when it opens.

If an initial date range is provided, initialDateRange.start and initialDateRange.end must both fall between or on firstDate and lastDate. For all of these DateTime values, only their dates are considered. Their time fields are ignored.

If initialDateRange is non-null, then it will be used as the initially selected date range. If it is provided, initialDateRange.start must be before or on initialDateRange.end.


final DateTimeRange? initialDateRange;