turf
turf copied to clipboard
bbox longitudes incorrect for geojson FeatureCollection spanning the anti-meridian
turf 6.3.0
Here is a link to geoJson from the US Census TIGER web that spans the antimeridian:
US Census TIGER Alaska outline
02 is the FIPS state code for Alaska.
This geoJson is a FeatureCollection with one Feature, a MultiPolygon with 50 components of coordinates.
turf.bbox(alaskaFeatureCollection) =>
[-179.23108599959195, 51.17509200018345, 179.85968100035376, 71.43978600002835]
The latitudes are correct but the longitudes are not.
For comparison:
d3.geoBounds(alaskaFeatureCollection) =>
[[172.34784599966287, 51.17509200018345], [-129.97416699982122, 71.43978600002835]]
Thank you for this project.