startOfMonth property
DateTime
get
startOfMonth
The first day of the month that contains this date.
DateTime(2025, 6, 15).startOfMonth; // DateTime(2025, 6, 1)
Implementation
DateTime get startOfMonth => DateTime(year, month, 1);