This creates a new component, BasemapToggle.js
When this toggle (a simple <select> element) is changed, it fires a ViewAction
The active basemap is stored in MapStore.
The Map needs to check if the basemap has changed when receiving new properties, similar to the way it handles new active layers.
However, when the basemap changes, the entire map needs to be re-rendered, and any currently active layers need to be cleared and redrawn once the new basemap has a chance to load.
This creates a new component,
BasemapToggle.js
When this toggle (a simple<select>
element) is changed, it fires aViewAction
The active basemap is stored inMapStore
. TheMap
needs to check if the basemap has changed when receiving new properties, similar to the way it handles new active layers. However, when the basemap changes, the entire map needs to be re-rendered, and any currently active layers need to be cleared and redrawn once the new basemap has a chance to load.