AnsweredAssumed Answered

LayerList widget bug (arcgis js api 4.x)

Question asked by mvs on Sep 22, 2020
Latest reply on Sep 22, 2020 by KEkenes-esristaff

LayerList widget has a documented feture:

To hide layers in the map from the LayerList widget, you must set the listMode property on the desired layers to hide.

I tried to use this feature over several layers in a loop and found strange behavior - only each "second" layer is hidden when you change listMode property of several layers in a loop.


Here is an example: 


If you turn off "first half" of layers (from 0 to 4) only layers 0,2,4 are hidden actually and #1 and 3 are still here!