Maximum call stack size exceeded with "maxNativeZoom"
Closed this issue ยท 7 comments
Hello!
I found out that if "maxNativeZoom" is used and it is exactly 2 less then "maxZoom" when maximum zoom reached - " Maximum call stack size exceeded " is thrown.
L.tileLayer('http://{s}.tile.osm.org/{z}/{x}/{y}.png', {
attribution: '© <a href="http://osm.org/copyright">OpenStreetMap</a> contributors',
maxNativeZoom: 14,
maxZoom: 16,
minZoom: 11,
}).addTo(map);
It should be exactly "maxZoom" - "maxNativeZoom" === 2 to get the error. I have tested it with your example.
"leaflet": "^1.4.0", "leaflet-active-area": "^1.1.0"
we're seeing something similar in our project with leaflet 1.5.1
@paulgreg do you have any advice on this or possible a chance to look at it?
hey @webmatrixxxl - @dopeters got a PR merged in that helped fix this issue for us. it's not on NPM yet, however we installed the package via the git repo like so:
"leaflet-active-area": "https://github.com/Mappy/Leaflet-active-area.git"
hope it helps :)
Hello,
Yes, sorry for the delay.
Could you confirm that @dopetersโs PR fixes your issue ?
If so, I would generate the npm package.
@colbyfayock @paulgreg
Hello. Any updates? We would not like to use the link to the repository in package.json
"leaflet-active-area": "https://github.com/Mappy/Leaflet-active-area.git"
did fix it for me ! thanks!!!
@webmatrixxxl does this resolve the issue for you as well?
Just published release 1.1.1 with the fix.