currentMonth function

DateTime currentMonth([
  1. DateTime? date
])

当前月

Implementation

DateTime currentMonth([DateTime? date]) {
  final now = date ?? DateTime.now();
  return DateTime(now.year, now.month);
}