<?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: Promise not working in arcgis js 4.19 in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/promise-not-working-in-arcgis-js-4-19/m-p/1073227#M73654</link>
    <description>&lt;P&gt;Do you have a snippet showing what layer promises is doing? Are they layer.loads() or queries? If you add a .catch() what is the error message? You wouldn't happen to be using Angular are you?&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 28 Jun 2021 15:28:49 GMT</pubDate>
    <dc:creator>ReneRubalcava</dc:creator>
    <dc:date>2021-06-28T15:28:49Z</dc:date>
    <item>
      <title>Promise not working in arcgis js 4.19</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/promise-not-working-in-arcgis-js-4-19/m-p/1073075#M73637</link>
      <description>&lt;P&gt;i am trying to promise in arcgis js 4.19 .&lt;/P&gt;&lt;P&gt;code :&lt;/P&gt;&lt;P&gt;promise.all(layerPromises)&lt;/P&gt;&lt;P&gt;.then(()=&amp;gt;{&lt;/P&gt;&lt;P&gt;console.log("hello")&lt;/P&gt;&lt;P&gt;})&lt;/P&gt;&lt;P&gt;**layerPromises is an array of promises**&lt;/P&gt;&lt;P&gt;when i run this code in 4.17 it is working fine but with 4.19 not able to exceute it&lt;/P&gt;</description>
      <pubDate>Mon, 28 Jun 2021 05:12:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/promise-not-working-in-arcgis-js-4-19/m-p/1073075#M73637</guid>
      <dc:creator>RitikaManderwal</dc:creator>
      <dc:date>2021-06-28T05:12:08Z</dc:date>
    </item>
    <item>
      <title>Re: Promise not working in arcgis js 4.19</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/promise-not-working-in-arcgis-js-4-19/m-p/1073227#M73654</link>
      <description>&lt;P&gt;Do you have a snippet showing what layer promises is doing? Are they layer.loads() or queries? If you add a .catch() what is the error message? You wouldn't happen to be using Angular are you?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Jun 2021 15:28:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/promise-not-working-in-arcgis-js-4-19/m-p/1073227#M73654</guid>
      <dc:creator>ReneRubalcava</dc:creator>
      <dc:date>2021-06-28T15:28:49Z</dc:date>
    </item>
    <item>
      <title>Re: Promise not working in arcgis js 4.19</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/promise-not-working-in-arcgis-js-4-19/m-p/1074076#M73694</link>
      <description>&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;i am not using angular it is javascript.&lt;/P&gt;&lt;P&gt;layerpromises are layer.loads().it is checking for everylayer loads successfully or not.&lt;/P&gt;&lt;P&gt;const fdwh = (view,featureLayer)=&amp;gt;{&lt;/P&gt;&lt;P&gt;try{&lt;/P&gt;&lt;P&gt;return new Promise((resolve,reject)=&amp;gt;{&lt;/P&gt;&lt;P&gt;view.whenLayerView(featureLayer).then((layerview) =&amp;gt; {&lt;/P&gt;&lt;P&gt;watchutil.whenFalseOnce(layerView,"updating").then(()=&amp;gt;{&lt;/P&gt;&lt;P&gt;resolve();&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;for(var i =0;i&amp;lt;featurelayerarray.length;i++)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;layerPromises.push(fdwh (view,featurelayerarray[i]))&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;promise.all(layerPromises)&lt;/P&gt;&lt;P&gt;.then(()=&amp;gt;{&lt;/P&gt;&lt;P&gt;console.log("hello")&lt;/P&gt;&lt;P&gt;})&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jun 2021 11:19:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/promise-not-working-in-arcgis-js-4-19/m-p/1074076#M73694</guid>
      <dc:creator>RitikaManderwal</dc:creator>
      <dc:date>2021-06-30T11:19:00Z</dc:date>
    </item>
  </channel>
</rss>

