useLocation function

HistoryLocation useLocation(
  1. BuildContext context
)

Returns the current location from the nearest route scope.

Implementation

HistoryLocation useLocation(BuildContext context) {
  return RouteScopeProvider.of(context).location;
}