<?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 How would you debounce the response of a timeslider? in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-would-you-debounce-the-response-of-a/m-p/1369237#M83323</link>
    <description>&lt;P&gt;Currently, when you move the timeslider reactiveutils.watch()&amp;nbsp; picks up every individual movement (e.g. it would register every year between 1850 and 1900) along the timeslider. Its potentially too many responses, if you want to do something like setting a definition expression using the slider value. I only want to get the ending time extent once the I've released the mouse button. Thanks!&lt;/P&gt;</description>
    <pubDate>Thu, 11 Jan 2024 23:49:39 GMT</pubDate>
    <dc:creator>Josh-R</dc:creator>
    <dc:date>2024-01-11T23:49:39Z</dc:date>
    <item>
      <title>How would you debounce the response of a timeslider?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-would-you-debounce-the-response-of-a/m-p/1369237#M83323</link>
      <description>&lt;P&gt;Currently, when you move the timeslider reactiveutils.watch()&amp;nbsp; picks up every individual movement (e.g. it would register every year between 1850 and 1900) along the timeslider. Its potentially too many responses, if you want to do something like setting a definition expression using the slider value. I only want to get the ending time extent once the I've released the mouse button. Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 11 Jan 2024 23:49:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-would-you-debounce-the-response-of-a/m-p/1369237#M83323</guid>
      <dc:creator>Josh-R</dc:creator>
      <dc:date>2024-01-11T23:49:39Z</dc:date>
    </item>
    <item>
      <title>Re: How would you debounce the response of a timeslider?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-would-you-debounce-the-response-of-a/m-p/1370764#M83348</link>
      <description>&lt;P&gt;Hi there,&amp;nbsp;&lt;/P&gt;&lt;P&gt;You could listen to the pointer-up event on the timeSlider div to achieve what you are trying to do. Here is a codepen showing how it is done.&amp;nbsp;&lt;A href="https://codepen.io/U_B_U/pen/abMJdaL?editors=1000" target="_blank" rel="noopener"&gt;https://codepen.io/U_B_U/pen/abMJdaL?editors=1000&lt;/A&gt;&lt;/P&gt;&lt;P&gt;The following is the how you can do it.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;document.getElementById("timeSlider").addEventListener("pointerup",(event) =&amp;gt; {
  console.log("here is your time extent", timeSlider.timeExtent);
});&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You could also debounce when watching timeExtent using&amp;nbsp;&amp;nbsp;the debounce function technique mentioned in this article:&amp;nbsp;&lt;A title="https://davidwalsh.name/javascript-debounce-function" href="https://davidwalsh.name/javascript-debounce-function" target="_blank" rel="noreferrer noopener"&gt;JavaScript Debounce Function (davidwalsh.name)&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;-Undral&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jan 2024 23:11:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-would-you-debounce-the-response-of-a/m-p/1370764#M83348</guid>
      <dc:creator>UndralBatsukh</dc:creator>
      <dc:date>2024-01-16T23:11:30Z</dc:date>
    </item>
    <item>
      <title>Re: How would you debounce the response of a timeslider?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-would-you-debounce-the-response-of-a/m-p/1371298#M83372</link>
      <description>&lt;P&gt;I ended up going with the "pointerup" method. Exactly what I was looking for. Thank you!!&lt;/P&gt;</description>
      <pubDate>Wed, 17 Jan 2024 21:39:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-would-you-debounce-the-response-of-a/m-p/1371298#M83372</guid>
      <dc:creator>Josh-R</dc:creator>
      <dc:date>2024-01-17T21:39:34Z</dc:date>
    </item>
  </channel>
</rss>

