Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
A proposed extensions mechanism for GeoJSON

Extensions Object

A GeoJSON object MAY contain a member named Extensions which is an extensions object. An extensions object SHALL contain a set of key/value pairs describing the extensions in use in that GeoJSON object.

Key

The key is a machine-readable string that names the extension. A key SHOULD have a prefix that names the community responsible for naming the extension. A GeoJSON object SHOULD contain an extensions object to declare which extensions are in use. If a client supports one or more GeoJSON extensions, it SHOULD inspect the extensions object.

Value

The value is a human-readable string describing the extension. A value SHOULD contain a URL for a description of the extension.

Example

   {
       "type": "FeatureCollection",
       "extensions":{
           "jyutzler_extension": "A proposed extension for encoding extensions, 
           as described at https://gist.github.com/jyutzler/da33f075ac416d0445e7"
       },
       "features": [{
           "type": "Feature",
           "geometry": {
               "type": "Point",
               "coordinates": [102.0, 0.5]
           },
           "properties": {
               "prop0": "value0"
           }
       }]
   }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.