<?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 Experience Builder -  access pop-up for layers added through custom widget in Developers Questions</title>
    <link>https://community.esri.com/t5/developers-questions/experience-builder-access-pop-up-for-layers-added/m-p/1061969#M5882</link>
    <description>&lt;P&gt;Hi! Hopefully the correct forum for this question. My first time working with custom widgets in Experience Builder (v1.4), I thought I'd start with implementing and editing the layer toggle widget found here:&amp;nbsp;&lt;A href="https://github.com/Esri/arcgis-experience-builder-sdk-resources/tree/master/samples/widgets/view-layers-toggle" target="_blank" rel="noopener"&gt;https://github.com/Esri/arcgis-experience-builder-sdk-resources/tree/master/samples/widgets/view-layers-toggle&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;I notice that pop-ups for the layers added to the map through this widget cannot be accessed. Could anyone help me figure out what modifications I need to make to enable pop-ups? I thought adding defaultPopupTemplateEnabled: true where the featureLayer is added in widget.tsx would work, but no luck:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;      if (evt.target.value &amp;amp;&amp;amp; evt.target.value !== "") {
        // Create and add the new Feature Layer
        const featureLayer = new FeatureLayer({
          url: evt.target.value,
		  defaultPopupTemplateEnabled: true
        });
        this.state.jimuMapView.view.map.add(featureLayer);
        this.setState({
          featureLayerOnMap: featureLayer,
        });
      }
    } else {
      console.error(
        "You probably need to choose your map in the settings panel."
      );
    }
  };&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
    <pubDate>Wed, 26 May 2021 19:58:58 GMT</pubDate>
    <dc:creator>KayceeFaunce</dc:creator>
    <dc:date>2021-05-26T19:58:58Z</dc:date>
    <item>
      <title>Experience Builder -  access pop-up for layers added through custom widget</title>
      <link>https://community.esri.com/t5/developers-questions/experience-builder-access-pop-up-for-layers-added/m-p/1061969#M5882</link>
      <description>&lt;P&gt;Hi! Hopefully the correct forum for this question. My first time working with custom widgets in Experience Builder (v1.4), I thought I'd start with implementing and editing the layer toggle widget found here:&amp;nbsp;&lt;A href="https://github.com/Esri/arcgis-experience-builder-sdk-resources/tree/master/samples/widgets/view-layers-toggle" target="_blank" rel="noopener"&gt;https://github.com/Esri/arcgis-experience-builder-sdk-resources/tree/master/samples/widgets/view-layers-toggle&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;I notice that pop-ups for the layers added to the map through this widget cannot be accessed. Could anyone help me figure out what modifications I need to make to enable pop-ups? I thought adding defaultPopupTemplateEnabled: true where the featureLayer is added in widget.tsx would work, but no luck:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;      if (evt.target.value &amp;amp;&amp;amp; evt.target.value !== "") {
        // Create and add the new Feature Layer
        const featureLayer = new FeatureLayer({
          url: evt.target.value,
		  defaultPopupTemplateEnabled: true
        });
        this.state.jimuMapView.view.map.add(featureLayer);
        this.setState({
          featureLayerOnMap: featureLayer,
        });
      }
    } else {
      console.error(
        "You probably need to choose your map in the settings panel."
      );
    }
  };&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 26 May 2021 19:58:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/developers-questions/experience-builder-access-pop-up-for-layers-added/m-p/1061969#M5882</guid>
      <dc:creator>KayceeFaunce</dc:creator>
      <dc:date>2021-05-26T19:58:58Z</dc:date>
    </item>
  </channel>
</rss>

