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

Monkey patch core with to_geojson #54

Closed
3 tasks
Tracked by #247
BuonOmo opened this issue Jun 23, 2021 · 0 comments · Fixed by #56
Closed
3 tasks
Tracked by #247

Monkey patch core with to_geojson #54

BuonOmo opened this issue Jun 23, 2021 · 0 comments · Fixed by #56

Comments

@BuonOmo
Copy link
Member

BuonOmo commented Jun 23, 2021

As part of our RGeo core v3 roadmap, we would like easier geojson usage. Here's one of the steps to go in that direction.

The goal is to provide the next functions to all factories:

  • to_geojson / to_json giving a String geojson
  • as_geojson / as_json giving a Hash geojson
  • Factory#parse_geojson (similar to Factory#parse_wkt)

To be included in all factories, the easiest is to add the new module to RGeo::Feature::Instance which is in every factories.

Attention points:

  • Use MultiJson
  • Be perf aware
  • make sure to test all factories
  • write related rdoc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant