SymbolixAU / mapdeck

R interface to Deck.gl and Mapbox
https://symbolixau.github.io/mapdeck/articles/mapdeck.html
362 stars 40 forks source link

Return coordinates with map click event #379

Open Zekiye-VAP opened 7 months ago

Zekiye-VAP commented 7 months ago

Was wondering if it is possible to build in a feature that returns the lat and lon coordinates of a click event on a map? The goal would be to allow the user to click on the map and have a new point feature added in that place based on the returned coordinates.

Similar examples I have found a working example using the tmap package https://stackoverflow.com/questions/76335139/add-location-to-interactive-map-with-a-click-using-tmap-package-and-r-shiny

dcooley commented 7 months ago

I added this a few days ago into the master branch, but didn't record it as an issue - https://github.com/SymbolixAU/mapdeck/blob/master/NEWS.md#v036