Document layerGroup id option
See original GitHub issueL.layerGroup
has a function getLayer
that finds layers by ids, but how layers get ids is unexplained
L.layerGroup({ foo: L.tileLayer('') }).getLayer('foo') // no dice
Is there an id option for layers? This needs better explaining around.
Issue Analytics
- State:
- Created 10 years ago
- Reactions:6
- Comments:18 (10 by maintainers)
Top Results From Across the Web
Layer Groups and Layers Control - Leaflet - Leaflet
This tutorial will show you how to group several layers into one, and how to use the layers control to allow users to...
Read more >How to get Name/ID of featureGroup when layer is clicked
No. Leaflet does not have a concept of "parent group". A L.Layer can belong to zero, one, or many L.LayerGroup s, e.g.:
Read more >Does leaflet support user defined Layer identifiers
For example with a LayerGroup, the idea is to have a setId(<String> id) function that would allow leveraging the native removeLayer( ...
Read more >ol/layer/Group~LayerGroup - OpenLayers
ol/layer/Group~LayerGroup. import LayerGroup from 'ol/layer/Group.js'; ... new LayerGroup(options) ... maxResolution, number, yes, change:maxresolution.
Read more >Layer, group, and lock objects in Pages on Mac - Apple Support
You can work with and arrange the objects on a page in a number of ways: Layer (or stack) objects to create the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Leaflet 1.0 came out but there is still no way to access layers other than with
getLayerId(layer)
andgetLayer(id)
…Note that there is a fair amount of interest in something like this, you can see that in these two so questions that have garnered a decent number of votes: