Open adarshwebcastle opened 1 year ago
Will the alternative routes support avoidTolls/avoidHighways?
Will the alternative routes support avoidTolls/avoidHighways?
Yes,
lib/src/utils/polyline_request.dart
class PolylineRequest {
final PointLatLng origin;
final PointLatLng destination;
final TravelMode mode;
final String apiKey;
final List<PolylineWayPoint> wayPoints;
final bool avoidHighways;
final bool avoidTolls;
final bool avoidFerries;
final bool optimizeWaypoints;
I'm trying to use Third method # getRouteWithAlternatives using the version ^2.0.0 of this package as shown in the readMe to get alternative routes, but for this function it's params changed and showing an error like
The named parameter 'request' is required, but there's no corresponding argument. (Documentation) Try adding the required argument.
so an update to the readME file is required to show how to use this methodprevious method: -
result = await PolylinePoints().getRouteWithAlternatives(googleAPiKey, _originLatitude, _originLongitude, _destLatitude, _destLongitude);
new function params -
getRouteWithAlternatives( {required PolylineRequest request})