I have been searching, but have not found a way to do this...
I have several 'generic' layers that I want to show in my Control for users to toggle on and off... That works fine.
However, I would like to let the user select additional layers from a list, and have them toggle on and off as well. BUT, I do NOT want those layers added to the control. Instead, I want to add them to an external list (shown outside the map), and have a checkbox for each that the user can use to show/hide that layer on the map.
Potentially, the user could have 20+ additional layers selected, so adding them to the control is not good, as the list would be very long.
And no, I do not have any code to share, as I cannot find any way to add a layer to the map, without adding it to the control....