I currently have a Folium map with this LayerControl component. Would it be possible to fully customise the layer control panel? For example, I would like it to not show the map style button saying "cartodbdark_matter", and I would like it to be transparent. Can I achieve this with Folium? If not, what tool should I be using?
Folium – Fully Customizing LayerControl() on Web Mapping Projects
foliumleafletmappingweb-mapping
Best Answer
It's possible via combination of three informations
Layer
https://github.com/python-visualization/folium/blob/master/folium/map.py#L30 and one of the option states the followingNone
to not add automatically the baseLayer when usingfolium.Map
folium.TileLayer
for darkmatter to display the background layer but saying you do not want to display it in the control.To get transparent layer, we used the
opacity
option infolium.TileLayer
(1 = fully opaque, 0 fully transparent)A full sample available below can be used to "do the job"