woowoowoo
woowoowoo

Reputation: 185

Example for using directions in Mapbox GL-JS

The example for using the directions plugin doesn't seem to be working, so I'm at a bit of a loss.

By the look of it, however, it doesn't do what I want anyway. I want to offer users directions using a specific group of objects (to buildings on our university campus from the users' current location, or another building)

I'm hoping for an example that just provides a start and finish lat/lng and triggers a request for directions.

Make sense?

Upvotes: 1

Views: 826

Answers (1)

mollymerp
mollymerp

Reputation: 1602

The directions plugin was fixed with a new release yesterday, so that example you posted should work now.

You can check out how to make a request to the directions API using LatLng pairs in our api-docs and test it out in our API Playground.

Upvotes: 1

Related Questions