location property

  1. @override
RouteInformation get location
override

The current location, including the optional per-entry RouteInformation.state.

Implementation

@override
RouteInformation get location {
  final web.Location(:hash) = window.location;
  final path = hash.startsWith('#') ? hash.substring(1) : hash;
  final uri = Uri.parse(path.startsWith('/') ? path : '/$path');
  return RouteInformation(uri: uri, state: state?.userData);
}