Somebody knows how can I extract from DateTime the abbreviated name of the day of the week?
ej:
DateTime date = DateTime.now();
String dateFormat = DateFormat('dd-MM-yyyy hh:mm').format(date);
Result -> Fri
Somebody knows how can I extract from DateTime the abbreviated name of the day of the week?
ej:
DateTime date = DateTime.now();
String dateFormat = DateFormat('dd-MM-yyyy hh:mm').format(date);
Result -> Fri
Use 'E' as a date pattern (ABBR_WEEKDAY pattern)
DateFormat(DateFormat.ABBR_WEEKDAY).format(date);
Check this for more info: https://docs.flutter.io/flutter/intl/DateFormat-class.html