numberOfWeeks property
int
get
numberOfWeeks
Implementation
int get numberOfWeeks {
// https://en.wikipedia.org/wiki/ISO_week_date#Weeks_per_year
final isLongWeek = lastDay.weekday == Weekday.thursday ||
previous.lastDay.weekday == Weekday.wednesday;
return isLongWeek ? 53 : 52;
}