Multiple geometry modules

Show different geometries with different modules using different configurations

View on GitHub
SDK 1.0.0-rc.7

Everything outside Germany is dimmed, its states are tinted from one palette, and the two state layers trade places as you zoom.

  • geometryData returns the country and its states as boundary polygons, and show takes that response unchanged.
  • GeometriesModule.create runs three times on one map. Each instance owns its sources and layers, so their configs never collide.
  • fill: { style: 'inverted' } masks the map around a polygon instead of filling inside it, and fill.opacity accepts a zoom expression rather than a zoom listener.

Related examples