tilezen / mapbox-vector-tile

Python package for encoding & decoding Mapbox Vector Tiles
MIT License
241 stars 47 forks source link

Support encoding and decoding lists #64

Open zerebubuth opened 8 years ago

zerebubuth commented 8 years ago

MVT doesn't have a native list value type, but we can fake it by encoding lists to something like "list:" + value.to_json, and parse it from JSON when the prefix is list: when decoding. This runs the risk of decoding things which start with list: which aren't actually lists, but I think there are few enough of them?

nvkelso commented 8 years ago

Apparently Mapbox encodes raw JSON for nested properties (e.g.: for their file uploader > tiles tool).

nyurik commented 7 years ago

I just made an implementation proposal for objects and lists at https://github.com/mapbox/vector-tile-spec/issues/75#issuecomment-249655916