remainingTime function

String remainingTime(
  1. Duration startTime,
  2. Duration endTime
)

Implementation

String remainingTime(Duration startTime,Duration endTime){
  int diff = endTime.inMicroseconds - startTime.inMicroseconds;
  return Duration(microseconds: diff).toString().split(".").first;
}