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

precision argument #152

Open
timelyportfolio opened this issue Aug 13, 2018 · 2 comments
Open

precision argument #152

timelyportfolio opened this issue Aug 13, 2018 · 2 comments
Labels

Comments

@timelyportfolio
Copy link
Contributor

As we were working through r-spatial/mapedit#63, I learned from geoman-io/leaflet-geoman#306 (comment) that with Leaflet/Leaflet#5444 leaflet > 1.1 added a precision argument to toGeoJSON(). The new default of 6 is probably enough in most cases, but @schloerke and @bhaskarvk what would you think about adding a precision argument to leaflet.draw to adjust higher or lower?

@bhaskarvk
Copy link
Contributor

I'll be resuming development of leaflet.extras in Dec and will tackle this in that round. Thanks!

@trafficonese
Copy link
Owner

I was trying to include the precision argument. On the JS side the toGeoJSON respects the argument, but when it is returned to Shiny via Shiny.onInputChange, the coordinates will have maximum 6 digits unless one sets options(digits = 18).

So I am thinking of directly using that option with getOption("digits", 6) and not include a new argument.
What do you think @timelyportfolio ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants