weekLastDay method

DateTime weekLastDay([
  1. int lastDay = DateTime.saturday
])

Implementation

DateTime weekLastDay([int lastDay = DateTime.saturday]) => add(
      Duration(
        days: lastDay - weekday + (lastDay - weekday < 0 ? 7 : 0),
      ),
    ).mergeStart();