Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duration and distance for waypoints. #46

Open
prathammehta opened this issue Jun 3, 2018 · 4 comments
Open

Duration and distance for waypoints. #46

prathammehta opened this issue Jun 3, 2018 · 4 comments

Comments

@prathammehta
Copy link

The waypoint feature is awesome! Can you also expose the Duration and distance to each waypoint in the callback for onReady?
I believe Google's direction API response already contains that information.

Thanks for a great library!

@why-absystem
Copy link

@prathammehta , u can also get duration and distance from result.
result.duration
result.distance

@prathammehta
Copy link
Author

Yup. I know about that. It'll be awesome to be able to get the same information for each waypoint as well.

@bramus
Copy link
Owner

bramus commented Oct 17, 2018

Passing the original Google Directions response into the onReady callback looks like a good solution, to cater for more advanced/specific use cases.

I'll happily accept a PR that implements this.

@garydevenay
Copy link

I have created a pull request which includes a fix for this issue. #85

This includes each step in a journey, each which has its own individual duration.

miticous added a commit to miticous/react-native-maps-directions that referenced this issue Sep 25, 2020
miticous added a commit to miticous/react-native-maps-directions that referenced this issue Sep 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants