Agm-Direction icon indicating copy to clipboard operation
Agm-Direction copied to clipboard

agm-direction provideRouteAlternatives not working

Open AkramFaiz opened this issue 5 years ago • 1 comments

agm-direction provideRouteAlternatives not working.

<agm-map [latitude]="lat" [longitude]="lng" [zoom]="zoom"> <agm-marker [latitude]="lat" [longitude]="lng"> <agm-direction [origin]="origin" [destination]="destination" [waypoints]="waypoints" [provideRouteAlternatives]="altRoutes">

here altRoutes is set to 'true' (boolean)

AkramFaiz avatar Aug 26 '20 08:08 AkramFaiz

Hi @AkramFaiz

According to the Directions Requests, alternative routes won't show at the same time.

You can use onResponse event to get results, or check out the issue #81

  <agm-direction
   ...
   (onResponse)="onResponse($event)"
   >
  </agm-direction>
  public onResponse(event): void {
    console.log(event);
  }

explooosion avatar Sep 23 '20 12:09 explooosion