<?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 customize Zoom-Out Event in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046484#M72489</link>
    <description>&lt;P&gt;You could &lt;A href="https://developers.arcgis.com/javascript/latest/programming-patterns/#watching-for-property-changes" target="_self"&gt;watch&lt;/A&gt; for the change of the mapView's &lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#zoom" target="_self"&gt;zoom&lt;/A&gt; property&lt;/P&gt;</description>
    <pubDate>Tue, 13 Apr 2021 17:40:39 GMT</pubDate>
    <dc:creator>KenBuja</dc:creator>
    <dc:date>2021-04-13T17:40:39Z</dc:date>
    <item>
      <title>How to customize Zoom-Out Event</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046474#M72488</link>
      <description>&lt;P&gt;I use ESRI JS4.&amp;nbsp; I want to customize the Zoom-In/Out event somehow.&amp;nbsp; E.g., when the map is zoom-out to its limit, fire an event to do something.&amp;nbsp; Since the Zoom In/Out control is ESRI's build-in component, I don't know how to catch the object and then fire a customized event.&amp;nbsp; Hopefully, I can get hint from this thread.&amp;nbsp; Thanks.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 17:27:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046474#M72488</guid>
      <dc:creator>ShaningYu</dc:creator>
      <dc:date>2021-04-13T17:27:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to customize Zoom-Out Event</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046484#M72489</link>
      <description>&lt;P&gt;You could &lt;A href="https://developers.arcgis.com/javascript/latest/programming-patterns/#watching-for-property-changes" target="_self"&gt;watch&lt;/A&gt; for the change of the mapView's &lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#zoom" target="_self"&gt;zoom&lt;/A&gt; property&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 17:40:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046484#M72489</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2021-04-13T17:40:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to customize Zoom-Out Event</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046509#M72495</link>
      <description>&lt;P&gt;Ken:&amp;nbsp; Thanks for your response.&amp;nbsp; How to catch the view.zoom change?&amp;nbsp; Thanks if you can provide additional guide.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 18:13:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046509#M72495</guid>
      <dc:creator>ShaningYu</dc:creator>
      <dc:date>2021-04-13T18:13:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to customize Zoom-Out Event</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046537#M72501</link>
      <description>&lt;P&gt;This one way to do it, but the zoom level changes several times as you zoom to the next level. In one run, it&amp;nbsp; sent out 10 messages as it changed from zoom level 5 to 4.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;&amp;lt;!DOCTYPE html&amp;gt;
&amp;lt;html&amp;gt;
  &amp;lt;head&amp;gt;
    &amp;lt;meta charset="utf-8" /&amp;gt;
    &amp;lt;meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no" /&amp;gt;
    &amp;lt;title&amp;gt;Intro to MapView - Create a 2D map | Sample | ArcGIS API for JavaScript 4.18&amp;lt;/title&amp;gt;
    &amp;lt;style&amp;gt;
      html,
      body,
      #viewDiv {
        padding: 0;
        margin: 0;
        height: 100%;
        width: 100%;
      }
    &amp;lt;/style&amp;gt;

    &amp;lt;link rel="stylesheet" href="https://js.arcgis.com/4.18/esri/themes/light/main.css" /&amp;gt;
    &amp;lt;script src="https://js.arcgis.com/4.18/"&amp;gt;&amp;lt;/script&amp;gt;

    &amp;lt;script&amp;gt;
      require(["esri/Map", "esri/views/MapView"], function(Map, MapView) {
        var map = new Map({
          basemap: "topo-vector"
        });

        var view = new MapView({
          container: "viewDiv",
          map: map,
          zoom: 4,
          center: [15, 65] // longitude, latitude
        });
        
        view.watch('zoom', zoomChanged);
        
        function zoomChanged(newValue, oldValue, property, object){
          console.log("New value: ", newValue,
              "&amp;lt;br&amp;gt;Old value: ", oldValue,
              "&amp;lt;br&amp;gt;Watched property: ", property,
              "&amp;lt;br&amp;gt;Watched object: ", object);
        }
        
      });
    &amp;lt;/script&amp;gt;
  &amp;lt;/head&amp;gt;

  &amp;lt;body&amp;gt;
    &amp;lt;div id="viewDiv"&amp;gt;&amp;lt;/div&amp;gt;
  &amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This thread shows better way to do it: &lt;A href="https://community.esri.com/t5/arcgis-api-for-javascript/how-to-simulate-listening-for-zoom-end-in-the-4-x-framework/m-p/215224" target="_blank"&gt;https://community.esri.com/t5/arcgis-api-for-javascript/how-to-simulate-listening-for-zoom-end-in-the-4-x-framework/m-p/215224&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 18:40:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-customize-zoom-out-event/m-p/1046537#M72501</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2021-04-13T18:40:33Z</dc:date>
    </item>
  </channel>
</rss>

