Skip to content
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

toGeoJSON precision parameter is not documented #6344

Closed
tylkomat opened this issue Sep 21, 2018 · 2 comments
Closed

toGeoJSON precision parameter is not documented #6344

tylkomat opened this issue Sep 21, 2018 · 2 comments

Comments

@tylkomat
Copy link

tylkomat commented Sep 21, 2018

Please Document the precision Parameter for the toGeoJSON method.
I took me quite some time to figure out why my calculated area where not same for leaflet layer and geojson layer.

I don't know why this precision even exists. When I convert a layer to geojson I would like to keep the precision as it was originally. Why would I want to loose it?

@rkatka
Copy link
Contributor

rkatka commented Oct 17, 2018

Addressed in PR: #6375

@perliedman
Copy link
Member

@tylkomat the reason is that the GeoJSON spec recommends 6 decimal places, which we default to.

perliedman pushed a commit that referenced this issue Jan 17, 2019
* Added LeafDoc for toGeoJSON's precision

* Added LeafDoc for toGeoJSON's precision argument
@mourner mourner closed this as completed Jan 17, 2019
Schleuse pushed a commit to Schleuse/Leaflet that referenced this issue Dec 3, 2019
…#6375)

* Added LeafDoc for toGeoJSON's precision

* Added LeafDoc for toGeoJSON's precision argument
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

No branches or pull requests

4 participants