format static method

String format(
  1. DateTime dateTime, {
  2. dynamic format = 'yyyy-MM-dd HH:mm:ss',
  3. dynamic locale = 'id_ID',
})

Implementation

static String format(DateTime dateTime, {format = 'yyyy-MM-dd HH:mm:ss', locale = 'id_ID'}) {
  initializeDateFormatting(locale);
  return DateFormat(format, locale).format(dateTime);
}