MichaelSolati / geofirestore-js

Location-based querying and filtering using Firebase Firestore.
https://geofirestore.com
MIT License
505 stars 58 forks source link

Search by Road Distance #74

Closed rajeshgadepalli closed 5 years ago

rajeshgadepalli commented 5 years ago

Is it possible in geofirestore to get results by the road distance ?

Right now, when the center and radius are provided, geofirestore returns all points located within the radius basing on the straight line distance.

If i provide the center and the road distance, would like to get all points within that distance.

Regards, Rajesh

itwasmattgregg commented 5 years ago

You would probably have to hook into a google maps api or similar to get that kind of information. Direct line will get you close right? Then you could filter further on the client.

MichaelSolati commented 5 years ago

@rajeshgadepalli this is very much above the scope or this project. You'd probably want to look into bounding boxes, so you would pass in a polyline, get the bounding boxes and then check if the point exists in the bounding boxes.