formatMediumDate method

  1. @override
String formatMediumDate (
  1. DateTime date
)
override

Formats the date using a medium-width format.

Abbreviates month and days of week. This appears in the header of the date picker invoked using showDatePicker.

Examples:

  • US English: Wed, Sep 27
  • Russian: ср, сент. 27

Implementation

@override
String formatMediumDate(DateTime date) {
  final String day = _shortWeekdays[date.weekday - DateTime.monday];
  final String month = _shortMonths[date.month - DateTime.january];
  return '$day, $month ${date.day}';
}