<?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: How to get custom widgets list on mapView? in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211351#M19528</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yang,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; I use private stuff all the time in my code I just have to test each new release of the API that it still exists and works as it did previously.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 02 Jan 2018 14:35:57 GMT</pubDate>
    <dc:creator>RobertScheitlin__GISP</dc:creator>
    <dc:date>2018-01-02T14:35:57Z</dc:date>
    <item>
      <title>How to get custom widgets list on mapView?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211348#M19525</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In the 4.x API there is no mention of a way to get a list of all widgets&amp;nbsp;that have been added to the mapView via mapView.ui.add();&amp;nbsp; MapView only provides the notion of 'default' widgets via the ui.components property.&amp;nbsp; Not sure why there is a distinction between default widgets and ones custom added, but there is, and it feels strange they are treated differently.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to implement responsive widgets and need a way to derive the active widgets list at any given time. I'm using a combination of default widgets and custom widgets.&amp;nbsp; It appears I need to manage this list manually outside of the mapView instance?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 31 Dec 2017 07:23:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211348#M19525</guid>
      <dc:creator>yangwen</dc:creator>
      <dc:date>2017-12-31T07:23:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to get custom widgets list on mapView?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211349#M19526</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yang,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;I am not sure why they do not give custom widget either but you can get all the UI widget components (the actual components not the string name) using the view.ui._components.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Jan 2018 14:23:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211349#M19526</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2018-01-02T14:23:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to get custom widgets list on mapView?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211350#M19527</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Robert, console logged the _component property and yes I do see an array with length that matches the number of widgets I've added.&amp;nbsp; However given it's not part of the official API and&amp;nbsp;I assume their style intended for this to be a private member, I'm hesitant to rely on it for my logic.&amp;nbsp; Looks like I'll just manage the widgets state outside of the arcGIS instance&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Jan 2018 14:31:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211350#M19527</guid>
      <dc:creator>yangwen</dc:creator>
      <dc:date>2018-01-02T14:31:13Z</dc:date>
    </item>
    <item>
      <title>Re: How to get custom widgets list on mapView?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211351#M19528</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yang,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; I use private stuff all the time in my code I just have to test each new release of the API that it still exists and works as it did previously.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Jan 2018 14:35:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211351#M19528</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2018-01-02T14:35:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to get custom widgets list on mapView?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211352#M19529</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The other issue is, none of the _component properties contain a string value that differentiate the custom widgets.&amp;nbsp; The top level id property is only populated for the 'default' widgets zoom and attribution.&amp;nbsp; The 'custom' widgets from arcgis' out of box library do not have the id property populated.&amp;nbsp; I've looked through the nested props too.&amp;nbsp; None of them seem to hold the identifier for the widget...&amp;nbsp; Very strange of how the default and custom&amp;nbsp;widgets are differentiated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Jan 2018 14:41:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211352#M19529</guid>
      <dc:creator>yangwen</dc:creator>
      <dc:date>2018-01-02T14:41:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to get custom widgets list on mapView?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211353#M19530</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yang,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;You can get the widget type by using declaredClass:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="token function"&gt;setTimeout&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword token"&gt;function&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; view&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;ui&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;_components&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;forEach&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword token"&gt;function&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;comp&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; console&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;info&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;comp&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;widget&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;declaredClass&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;200&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 10:24:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211353#M19530</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2021-12-11T10:24:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to get custom widgets list on mapView?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211354#M19531</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Judging by ArcGIS' sample codes, it appears the pattern for toggling widgets is simply add / remove them.&amp;nbsp; As such,&amp;nbsp; I'm going to need to manage the widgets list anyway outside of the view instance, so I'll just take this approach instead of relying on the private prop.&amp;nbsp; But&amp;nbsp;good tip the decalredClass method! I missed that in the API doc.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Jan 2018 15:13:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-get-custom-widgets-list-on-mapview/m-p/211354#M19531</guid>
      <dc:creator>yangwen</dc:creator>
      <dc:date>2018-01-02T15:13:38Z</dc:date>
    </item>
  </channel>
</rss>

