8.1.1 BasemapToggle
8.1.1 BasemapToggle ksc178.1.1 BasemapToggle (deprecated)
There are four key steps in implementing this widget:
- Set the basemap property of the Map object to the basemap you want the user to see when the app loads.
- Create the new BasemapToggle object, associating it with a View.
- Set the BasemapToggle’s nextBasemap property to the other basemap you’d like the user to be able to switch to.
- Add the widget to the desired screen location.
See the Pen L8_BasemapToggle_widget by Jim Detwiler (@jimdetwiler) on CodePen.