Skip to content

Conversation

valerino
Copy link

@valerino valerino commented Oct 3, 2023

No description provided.

@domoritz
Copy link
Owner

Thanks for the updates. Why is this functionality required to be inside the plugin rather than something controlled from the outside (by listening to location updates on the map and then calling stop on the plugin)?

@urb4nc4rl
Copy link

I'm not the OP but I also came here looking for this functionality.

In my case, I'm using React, and I'd like to have more fine-grained control over the panning/zoom when the user's location is found, panning to a viewRect which encompasses both their location and also a target marker for their destination.

Because leaflet-locatecontrol does not expose the native event, I'd need to add a second custom component inside <MapContainer> simply to hook into this event and pass it up to the parent.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants