firstDayOfMonth property

  1. @useResult
DateTime get firstDayOfMonth

The first day of the month.

DateTime(2023, 4, 11).firstDayOfMonth; // 2023-04-01

Implementation

@useResult DateTime get firstDayOfMonth => copyWith(day: 1, hour: 0, minute: 0, second: 0, millisecond: 0, microsecond: 0);