Add a precision argument to toGeoJSON method #5237

hrishiballal opened this Issue Jan 8, 2017 · 0 comments


None yet

1 participant

  • I'm reporting a bug, not asking for help
  • I've looked at the documentation to make sure the behaviour is documented and expected
  • I'm sure this is a Leaflet code issue, not an issue with my own code nor with the framework I'm using (Cordova, Ionic, Angular, React…)
  • I've searched through the issues to make sure it's not yet reported

How to reproduce

  • Leaflet version I'm using: 1.0.2
  • Browser (with version) I'm using: Firefox / Chrome
  • OS/Platform (with version) I'm using: Mac

This is a feature request. It would be nice to have a optional precision argument to the toGeoJSON() methods. The IETF spec recommends 6 decimals but Leaflet usually gives more than 6 for co-ordinates. It will be nice to be able to specify a precision argument with the default being 6.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment