getPreviousRoute method

Route? getPreviousRoute()

Get the previous route.

Implementation

Route<dynamic>? getPreviousRoute() {
  if (_routeHistory.length < 2) return null;
  return _routeHistory[_routeHistory.length - 2];
}