Skip to content

Instantly share code, notes, and snippets.

@nbogie
Last active September 11, 2022 16:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nbogie/aae824e8639a4917b2b70620577491bc to your computer and use it in GitHub Desktop.
Save nbogie/aae824e8639a4917b2b70620577491bc to your computer and use it in GitHub Desktop.
geoJSON github markdown diagram example

Mapping GeoJSON/TopoJSON files on GitHub ( following the geoJSON spec )

{
  "type": "Topology",
  "objects": {
    "example": {
      "type": "GeometryCollection",
      "geometries": [
        {
          "type": "Point",
          "properties": {"label": "larry", "title": "larry title"},
                    "coordinates": [-3.3648735, 56.04]

        },
        {
          "type": "Point",
          "properties": {"label": "curly"},
                    "coordinates": [-0.1276474, 51.5073219]
        }
      ]
    }
  }
}

Diagram 2 - attempting to get markers

{
  "type": "Topology",
  "objects": {
    "example": {
      "type": "FeatureCollection",            
      "features": [
      {
        "type":"Feature",
        "geometry":
            {
                "type":"Point",
                "coordinates":[-3.3648735, 56.04]
            },
            "properties":{"label":"W","title":"World Wide Web"}
      }     
      ]
    }
  }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment