isDateBefore method

dynamic isDateBefore (
  1. dynamic date1,
  2. dynamic date2
)

Implementation

isDateBefore(date1, date2) {
  DateTime _date1 = DateTime(date1.year, date1.month, date1.day);
  DateTime _date2 = DateTime(date2.year, date2.month, date2.day);
  return _date1.isBefore(_date2);
}