-
Notifications
You must be signed in to change notification settings - Fork 353
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
<Question> Change zoom level #680
Comments
Leaflet maps offer a Suppose you have a simple map, you could do something like this const map = new L.Map(); // your init logic goes here
const currentZoom = map.getZoom();
map.setZoom(currentZoom - 1); |
Thanks for this suggestion! It is only working after L.Routing.control(...).addTo(map); is finished. |
Leaflet maps fire a map.on('load', () => {
map.setZoom(map.getZoom() - 1);
}); |
Thanks, that's what I was searching for. But sad, that it is not possible to modify the fitting directly. |
Hi there,
I didn't find some option to customize the zoom level.
I don't wanne use manual zooming¢ering. I would like to use the fitSelectedRoutes true defaults but zooming out one step.
Background: I am using custom markers and they are cutting of :(
Thanks for any help or suggestions.
The text was updated successfully, but these errors were encountered: