tangrams / tangram

WebGL map rendering engine for creative cartography
https://tangram.city
MIT License
2.22k stars 290 forks source link

untiled datasource from object #754

Closed Zaitsev closed 4 years ago

Zaitsev commented 4 years ago

TANGRAM VERSION:

latest

Is it possible to add untiled datasource not from file but from JS object etc:

sources:
    overlay:
        type: GeoJSON
        url: |
               function(){return some_on_the_fly_geojson()}
bcamper commented 4 years ago

Not in that manner in the scene file, but you can use the scene.setDataSource() method to provide GeoJSON for a source like that at runtime.