<?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: With Dojo gone, some questions on 4.25 and ES modules in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/with-dojo-gone-some-questions-on-4-25-and-es/m-p/1340974#M82539</link>
    <description>&lt;P&gt;Thanks Andy! This is old but it’s been a big learning curve for me—including Webpack bundling—and I’m just now getting a handle on some of this (as I get time apart from normal daily work).&lt;/P&gt;&lt;P&gt;The native fetch works well. Thanks for that.&lt;/P&gt;&lt;P&gt;I couldn’t figure out Etags or the esri/request stuff. But the cacheBust seemed to be fixed with Webpack bundling. I have the output set to '[name].[contenthash].bundle.js' which looks like it gives a new alphanumeric id to the file name. That should force a cachebust.&lt;/P&gt;&lt;P&gt;The ‘remove’ also seems to work for onclick listening.&lt;/P&gt;&lt;P&gt;Thanks again for the directions to look.&lt;/P&gt;</description>
    <pubDate>Tue, 24 Oct 2023 15:58:46 GMT</pubDate>
    <dc:creator>DanielWebb</dc:creator>
    <dc:date>2023-10-24T15:58:46Z</dc:date>
    <item>
      <title>With Dojo gone, some questions on 4.25 and ES modules</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/with-dojo-gone-some-questions-on-4-25-and-es/m-p/1236610#M79506</link>
      <description>&lt;P&gt;I’ve been playing with ES Modules in the ArcGIS API for JavaScript 4.25. Dojo is gone, so I have some questions.&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Is there an equivalent for “dojo/text!./somehtml.html”?&lt;/LI&gt;&lt;LI&gt;Is there an equivalent for dojoConfig = {cacheBust: true}? It’s very helpful to always get fresh resources so that users get code changes right away without needing to clear their cache. Is there a way to cacheBust ES modules?&lt;/LI&gt;&lt;LI&gt;Is there an equivalent for “connect.disconnect”? I used this to disconnect any tools that needed to click the map. Is there a way in 4.25 to disconnect the view.hitTest?&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;The more I work with ES modules, I may have more questions. But these are three so far.&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 30 Nov 2022 21:30:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/with-dojo-gone-some-questions-on-4-25-and-es/m-p/1236610#M79506</guid>
      <dc:creator>DanielWebb</dc:creator>
      <dc:date>2022-11-30T21:30:34Z</dc:date>
    </item>
    <item>
      <title>Re: With Dojo gone, some questions on 4.25 and ES modules</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/with-dojo-gone-some-questions-on-4-25-and-es/m-p/1236647#M79509</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/4984"&gt;@DanielWebb&lt;/a&gt;, good questions, they related to both the AMD and ES modules:&lt;/P&gt;&lt;P&gt;1. No. You can use esri/request or use native fetch directly to load HTML as a string into your app&lt;/P&gt;&lt;P&gt;2. This can be handled through industry-standard patterns such as using &lt;A href="https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/ETag" target="_self"&gt;Etags&lt;/A&gt;. You can also set the &lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-request.html#RequestOptions" target="_self"&gt;cacheBust option&lt;/A&gt; in esri/request, but this is a different implementation from dojo, instead of adding a param, it tells fetch to make a conditional request. If you always want to cacheBust, then you can use a &lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-config.html#RequestInterceptor" target="_self"&gt;requestInterceptor with the url set to null&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;3.&lt;SPAN&gt;You can remove event listeners &lt;A href="https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/removeEventListener" target="_self"&gt;natively&lt;/A&gt;. If you are using an&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-View.html#on" target="_self"&gt; "on" listener&lt;/A&gt;, you can remove those using the APIs &lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-core-Handles.html#remove" target="_self"&gt;remove()&lt;/A&gt; method. &lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Nov 2022 22:52:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/with-dojo-gone-some-questions-on-4-25-and-es/m-p/1236647#M79509</guid>
      <dc:creator>AndyGup</dc:creator>
      <dc:date>2022-11-30T22:52:18Z</dc:date>
    </item>
    <item>
      <title>Re: With Dojo gone, some questions on 4.25 and ES modules</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/with-dojo-gone-some-questions-on-4-25-and-es/m-p/1340974#M82539</link>
      <description>&lt;P&gt;Thanks Andy! This is old but it’s been a big learning curve for me—including Webpack bundling—and I’m just now getting a handle on some of this (as I get time apart from normal daily work).&lt;/P&gt;&lt;P&gt;The native fetch works well. Thanks for that.&lt;/P&gt;&lt;P&gt;I couldn’t figure out Etags or the esri/request stuff. But the cacheBust seemed to be fixed with Webpack bundling. I have the output set to '[name].[contenthash].bundle.js' which looks like it gives a new alphanumeric id to the file name. That should force a cachebust.&lt;/P&gt;&lt;P&gt;The ‘remove’ also seems to work for onclick listening.&lt;/P&gt;&lt;P&gt;Thanks again for the directions to look.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Oct 2023 15:58:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/with-dojo-gone-some-questions-on-4-25-and-es/m-p/1340974#M82539</guid>
      <dc:creator>DanielWebb</dc:creator>
      <dc:date>2023-10-24T15:58:46Z</dc:date>
    </item>
  </channel>
</rss>

