firstDayOfYear property
DateTime
get
firstDayOfYear
Returns DateTime
object of First Day of the week.
final checkDate =
DateTime.parse('2023-09-16 20:18:00.123456789z');
checkDate.firstDayOfWeek; // 11-09-2023
This will not consider time Parameters.
Implementation
DateTime get firstDayOfYear => DateTime(year, 1, 1);