xando / commitcoffee

Home Page:https://xando.github.io/commitcoffee/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Use GeoJSON rather than arbitrary JSON schema

benbalter opened this issue · comments

Cool idea. One suggestion: if you store the locations as GeoJSON rather than a purpose-built JSON schema you'll get a few advantages:

  1. GitHub will natively render the GeoJSON. Here's an example of bars in DC with WIFI. You could consume the GeoJSON directly into Leaflet (open source FTW) or even use the embed endpoint to embed the map directly, alleviating the need for complex client-side logic. (Raw GeoJSON)
  2. Rather than having to manually edit and geocode the JSON file, you could use something like geojson.io, so that people could edit the list directly in their browser
  3. It'd be an open format that could be natively consumed elsewhere.

GeoJSON looks right. A bit to verbose for my needs but still looks like something that I should use it here.
I have quite a few merges to perform with old format then will replace it with GeoJSON.

Thanks for the suggestion

Hi,

I've already added validateplaces.py to validate and merge data from different commiters. So generating differently formed json was a piece of cake: https://github.com/xando/commitcoffee/blob/gh-pages/places.geojson
I think it looks good :)

I still would like to have GeoJSON rather than custom schema. Reopening this one.

is there any progress on this? should i rather submit my places in the geojson format?

update: just saw that it's done automatically.

Yeah; on merge we generate both JSON and geojson 👍