Comments (2)
@esamelson You could probably single step through the fitBounds code and see where the zoom calculations go wrong and the NaN appears, that would be helpful. If not, it would probably be easiest to debug this if we could write a test case for it.
Either you can open a PR with a new test case, or provide the failing input/outputs to the function so that we can write one.
If you want to go the PR route, please add a test case in test directory, something like:
import {fitBounds} from '../src';
test('fitBounds', t => {
const result = fitBounds(<Your failing parameters go here>);
t.equal(result.latitude, ..., 'got expected latitude');
t.equal(result.longitude, ..., 'got expected latitude');
t.equal(result.zoom, ..., 'got expected zoom');
t.end();
});
Note, you would need to sign our open source contributor form as well.
from react-map-gl.
Well, I stepped through the fitBounds code and discovered the error was on my end after all. So sorry for wasting your time @ibgreen .
from react-map-gl.
Related Issues (20)
- [Bug] incompatible dom objects within the react landscape HOT 4
- When setting maxZoom and dragging map around markers are moving all over the place [Bug] HOT 1
- [Bug] [docs] Link to MapLibre API docs are broken
- [Feat] Add support for latest Mapbox rendering release (V3) HOT 2
- [Bug] Input data given to 'xxx' is not a valid GeoJSON object HOT 3
- [Bug] Map loading issue on resizing width HOT 1
- [Bug] Missing tiles breaks Layer props update HOT 1
- [Bug] Mapbox queryRenderedFeatures() returns empty array HOT 1
- [Bug] Jump To does not center the map at the point you click on HOT 1
- [Bug] Blurred textures on ultrawide monitors HOT 1
- [Bug] Map projection "globe" is not working in react-map-gl HOT 1
- Next14/Remix HOT 1
- [Feat] Fetch tiles using axios HOT 3
- [Bug] React 19: "Warning: Invalid prop `source` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props."
- [Feat] upgrade to fit `[email protected]` HOT 8
- [Bug] mapRef.current is null inside `onLoad` HOT 4
- Issues with useControl when upgrading to nextjs 14.2
- [Bug] Unexpected map distortion with sticky elements
- [Feat] Update react-map.gl Footer
- [Feat] Use the extended MapLibre CustomRenderMethod
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-map-gl.