nowDateOnly function

DateTime nowDateOnly({
  1. int? days,
})

now, but without the time portion (plus days if passed in)

Implementation

DateTime nowDateOnly({int? days}) {
  var date = dateOnly(new DateTime.now());

  if (days != null) {
    date = date.add(new Duration(days: days));
  }

  return date;
}