<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Hide GroupLayer on LayerList by default (on page load) in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-grouplayer-on-layerlist-by-default-on-page/m-p/1236142#M79481</link>
    <description>&lt;P&gt;Thank you so much!&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 29 Nov 2022 20:37:33 GMT</pubDate>
    <dc:creator>klzheng</dc:creator>
    <dc:date>2022-11-29T20:37:33Z</dc:date>
    <item>
      <title>Hide GroupLayer on LayerList by default (on page load)</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-grouplayer-on-layerlist-by-default-on-page/m-p/1236121#M79479</link>
      <description>&lt;P&gt;Hello, does anyone know how to hide an entire GroupLayer by default? Meaning that when the page loads, one of the GroupLayers are hidden (eye icon crossed out) on the LayerList.&lt;/P&gt;&lt;P&gt;Here is what it looks like right now (on page load):&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="klzheng_0-1669751549553.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/57171i7BE2B6235F8B0A10/image-size/medium?v=v2&amp;amp;px=400" role="button" title="klzheng_0-1669751549553.png" alt="klzheng_0-1669751549553.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;As you can see on the LayerList, both "eye" icons are not crossed out&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is what I am trying to achieve:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="klzheng_1-1669751605554.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/57172iE854D3E4E16D41BF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="klzheng_1-1669751605554.png" alt="klzheng_1-1669751605554.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;You can see that the first GroupLayer is toggled to be hidden. But I was only able to do this after the page loads, is there a way to code it so that the first GroupLayer would be toggled to be hidden by default? Thanks!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is the codepen:&amp;nbsp;&lt;A href="https://codepen.io/klzheng/pen/oNyMqwB?editors=1000" target="_blank"&gt;LayerList widget with actions | Sample | ArcGIS API for JavaScript 4.25 (codepen.io)&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2022 19:54:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-grouplayer-on-layerlist-by-default-on-page/m-p/1236121#M79479</guid>
      <dc:creator>klzheng</dc:creator>
      <dc:date>2022-11-29T19:54:57Z</dc:date>
    </item>
    <item>
      <title>Re: Hide GroupLayer on LayerList by default (on page load)</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-grouplayer-on-layerlist-by-default-on-page/m-p/1236127#M79480</link>
      <description>&lt;P&gt;Set the GroupLayer's visibility to false when you construct it&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var incomeGroupLayer = new GroupLayer({
  title: "Income GroupLayer",
  layers: [tractIncomeLayer, countyIncomeLayer, stateIncomeLayer],
  visible: false
});&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2022 20:12:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-grouplayer-on-layerlist-by-default-on-page/m-p/1236127#M79480</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2022-11-29T20:12:42Z</dc:date>
    </item>
    <item>
      <title>Re: Hide GroupLayer on LayerList by default (on page load)</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-grouplayer-on-layerlist-by-default-on-page/m-p/1236142#M79481</link>
      <description>&lt;P&gt;Thank you so much!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2022 20:37:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-grouplayer-on-layerlist-by-default-on-page/m-p/1236142#M79481</guid>
      <dc:creator>klzheng</dc:creator>
      <dc:date>2022-11-29T20:37:33Z</dc:date>
    </item>
  </channel>
</rss>

