Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

15
  • Hey MKR, At first glance, looks like you have a lot going on in there. I'm no expert, but I think the data needs to be loaded first. I moved the bottom 3 geojson bits to the top. Then it says things like can't find A23, etc. Where is the data for Annular, etc? Then looks like some typos, layer.feature.properties.descriptio, missing 'n'. I would start way simple with the example from github, get it running, then 1 by 1 add new features.
    – timlohnes
    Commented Aug 11, 2021 at 16:45
  • First try with standard Leaflet layer control L.control.layers(maptiles, overlays).addTo(map); and see if everything works. To make this control work, overlays must have standard Leaflet structure (same as maptiles), not the one for L.control.groupedLayers.
    – TomazicM
    Commented Aug 11, 2021 at 17:02
  • I've tried with the basic Leaflet Geojson example leafletjs.com/examples/geojson and it's still the same
    – Geographos
    Commented Aug 12, 2021 at 10:39
  • This is then just question of debugging. Without having your code it's more or less impossible to find out what goes wrong. Your JSFiddle is missing data. Limit it to less data and include data in the code.
    – TomazicM
    Commented Aug 12, 2021 at 11:19
  • I've attached the full jsfiddle for it: jsfiddle.net/okezw4dL
    – Geographos
    Commented Aug 12, 2021 at 11:21