removeFragment method
Creates a Uri that differs from this only in not having a fragment.
If this Uri does not have a fragment, it is itself returned.
Example:
final uri =
Uri.parse('https://example.org:8080/foo/bar#frag').removeFragment();
print(uri); // https://example.org:8080/foo/bar
Implementation
@override
Uri removeFragment() => ToUri._(uri: _uri.removeFragment(), to: to, routeParameters: routeParameters);