question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Get @click coordinates on a vl-map

See original GitHub issue

Hello, Is it possible to get coordinates of a click on a vl-map component ?

I would need to get longitude and latitude in a function called by a @ click in <vl-map …>

Thanks

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
ghettovoicecommented, Mar 23, 2021

@a-lefe I can only append that with vuelayers you can also setup data projection globally:

<vl-map data-projection="EPSG:4326" @click="onClick">...</vl-map>

In this case event.coordinate will be already in EPSG:4326 projection.

0reactions
stale[bot]commented, Jun 2, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Getting Lat/Lng from a Click Event | Maps JavaScript API
This example listens for the click event, gets the latitude and longitude coordinates of the click from google.maps.MapMouseEvent.
Read more >
Capture Coordinates in Google Map on User Click
You should add the click listener on marker will give you the position of marker. ... It also uses the placeId to get...
Read more >
Calculating a Location from a Mouse Click - Maps API for ...
Calculating a Location from a Mouse Click. Obtain the latitude and longitude of a location within the map. This example displays a map...
Read more >
Get coordinates of the mouse pointer | Mapbox GL JS
Show mouse position on hover with pixel and latitude and longitude coordinates.
Read more >
How to capture the coordinates on a map on mouse click.
Hi,. I have an Add-In screen on which I have a Record button. Now my requirement is: When I click on the record...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found