<?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: Measurement , Sketch and SketchViewModel graphics not showing up in &amp;quot;@arcgis/core&amp;quot;: &amp;quot;^4.24.7&amp;quot; in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1226938#M79168</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/180"&gt;@AndyGup&lt;/a&gt;&amp;nbsp;, just confirm you I am not hosted&amp;nbsp;&lt;SPAN&gt;the ArcGIS API for JavaScript instead of that &amp;nbsp;managing the assets&amp;nbsp;&amp;nbsp;locally through help of below URL.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/es-modules/#managing-assets-locally" target="_blank" rel="noopener"&gt;https://developers.arcgis.com/javascript/latest/es-modules/#managing-assets-locally&lt;/A&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;After following the steps in above URL, under &lt;STRONG&gt;public&lt;/STRONG&gt; folder of my project components and esri subfolders are created successfully.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_0-1667190337124.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54787i881B58A260B4F2A7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AbdulSamim_0-1667190337124.png" alt="AbdulSamim_0-1667190337124.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As I mentioned earlier in my query esri sketch, sketch view model and measurement widget graphics are not showing up while using&amp;nbsp;"@arcgis/core": "^4.24.7".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_0-1667191051158.png" style="width: 775px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54788i3656F400B03704AD/image-dimensions/775x31?v=v2" width="775" height="31" role="button" title="AbdulSamim_0-1667191051158.png" alt="AbdulSamim_0-1667191051158.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_1-1667191134454.png" style="width: 768px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54789iD31062B355680362/image-dimensions/768x77?v=v2" width="768" height="77" role="button" title="AbdulSamim_1-1667191134454.png" alt="AbdulSamim_1-1667191134454.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 31 Oct 2022 04:39:55 GMT</pubDate>
    <dc:creator>AbdulSamim</dc:creator>
    <dc:date>2022-10-31T04:39:55Z</dc:date>
    <item>
      <title>Measurement , Sketch and SketchViewModel graphics not showing up in "@arcgis/core": "^4.24.7"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1226653#M79163</link>
      <description>&lt;P&gt;Migrated my project from esri-load module to arcgiscore (4.24.7), and managing assets locally(&lt;A title="managing-assets-locally" href="https://developers.arcgis.com/javascript/latest/es-modules/#managing-assets-locally" target="_self"&gt;managing-assets-locally&lt;/A&gt;&amp;nbsp;) in ReactJS. Measurement , Sketch and SketchViewMode widgets which are working fine in esri-load module , after migrating to arcgiscore graphics not showing up while drawing through these widgets and getting this below error while map is loading.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_1-1666971548848.png" style="width: 1071px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54714iBF5A250B740B3DAE/image-dimensions/1071x75?v=v2" width="1071" height="75" role="button" title="AbdulSamim_1-1666971548848.png" alt="AbdulSamim_1-1666971548848.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_2-1666971641837.png" style="width: 779px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54715i555CAA4E4750BB1F/image-dimensions/779x76?v=v2" width="779" height="76" role="button" title="AbdulSamim_2-1666971641837.png" alt="AbdulSamim_2-1666971641837.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Below screenshot while drawing through measurement widget&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_0-1666971338423.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54713iCA84256C383E05C3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AbdulSamim_0-1666971338423.png" alt="AbdulSamim_0-1666971338423.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&amp;nbsp;Measurement widget code&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;import React, { useEffect } from "react";


import Measurement1 from "@arcgis/core/widgets/Measurement";
import Expand from "@arcgis/core/widgets/Expand";

const Measurement = (props: any) =&amp;gt; {

    useEffect(() =&amp;gt; {
        const esrimeasurementWindow = document.getElementById("measurementDiv") as HTMLElement;

        const esriexpandMeasurement = new Expand({
            expandIconClass: "esri-icon-measure",
            view: props.impMap,
            content: esrimeasurementWindow,
        });

        props.impMap.ui.add(esriexpandMeasurement, "top-right");

        const measurement = new Measurement1();
        props.impMap.ui.add(measurement, "bottom-right");
        measurement.view = props.impMap;

        const distanceButton = document.getElementById("distance") as HTMLElement;
        distanceButton.addEventListener("click", () =&amp;gt; {
            distanceMeasurement();
        });

        const areaButton = document.getElementById("area") as HTMLElement;
        areaButton.addEventListener("click", () =&amp;gt; {
            areaMeasurement();
        });

        const clearButton = document.getElementById("clear") as HTMLElement;
        clearButton.addEventListener("click", () =&amp;gt; {
            clearMeasurements();
        });

        function distanceMeasurement() {
            const type = props.impMap.type;
            measurement.activeTool =
                type.toUpperCase() === "2D" ? "distance" : "direct-line";
            distanceButton.classList.add("active");
            areaButton.classList.remove("active");
        }

        function areaMeasurement() {
            measurement.activeTool = "area";
            distanceButton.classList.remove("active");
            areaButton.classList.add("active");
        }

        function clearMeasurements() {
            distanceButton.classList.remove("active");
            areaButton.classList.remove("active");
            measurement.clear();
        }
    }, []);


    return (
        &amp;lt;React.Fragment&amp;gt;
            &amp;lt;div id="measurementDiv" className="esri-component esri-widget"&amp;gt;
                &amp;lt;button
                    id="distance"
                    className="esri-widget--button esri-interactive esri-icon-measure-line"
                    title="Distance Measurement Tool"
                &amp;gt;&amp;lt;/button&amp;gt;
                &amp;lt;button
                    id="area"
                    className="esri-widget--button esri-interactive esri-icon-measure-area"
                    title="Area Measurement Tool"
                &amp;gt;&amp;lt;/button&amp;gt;
                &amp;lt;button
                    id="clear"
                    className="esri-widget--button esri-interactive esri-icon-trash"
                    title="Clear Measurements"
                &amp;gt;&amp;lt;/button&amp;gt;
            &amp;lt;/div&amp;gt;
        &amp;lt;/React.Fragment&amp;gt;
    )
}

export default Measurement;​&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Sketch widget code&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;import { useEffect } from "react";

import Expand from "@arcgis/core/widgets/Expand";
import GraphicsLayer from "@arcgis/core/layers/GraphicsLayer";
import Sketch from "@arcgis/core/widgets/Sketch";

const SketchSample = (props: any) =&amp;gt; {
    useEffect(() =&amp;gt; {

        const sketchgraphicsLayer = new GraphicsLayer({ title: "sketchgraphicsLayer" });
        props.impMap.map.add(sketchgraphicsLayer);

        const sketchModel = new Sketch({
            view: props.impMap,
            layer: sketchgraphicsLayer
        });

        const expandTopo = new Expand({
            expandIconClass: "esri-icon-authorize",
            view: props.impMap,
            content: sketchModel,
            collapseTooltip : "SketchSample",
            expandTooltip : "SketchSample"
        });

        props.impMap.ui.add(expandTopo, "top-right");

        sketchModel.on("create", (event: any) =&amp;gt; {
            if (event.state === "complete") {
                alert("Draw completed in SketchModel !!");
            }
        });
        
    }, []);

    return (null)
}

export default SketchSample;​&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;SketchViewModel widget code&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;//import { loadModules } from "esri-loader";
import React, { useEffect } from "react";
import "./SketchViewModelSample.css";

import Expand from "@arcgis/core/widgets/Expand";
import GraphicsLayer from "@arcgis/core/layers/GraphicsLayer";
import SketchViewModel from "@arcgis/core/widgets/Sketch/SketchViewModel";

const SketchViewModelSample = (props: any) =&amp;gt; {
    useEffect(() =&amp;gt; {

        const graphicsWindow = document.getElementById("drawGraphicsWindow") as HTMLElement;

        const graphicsLayer = new GraphicsLayer({ title: "sketchviewmodelgraphicsLayer" });
        props.impMap.map.add(graphicsLayer);

        const svModel = new SketchViewModel({
            view: props.impMap,
            layer: graphicsLayer
        });

        const selectRectangleButton = document.getElementById("create-by-rectangle") as HTMLElement;
        selectRectangleButton.addEventListener("click", () =&amp;gt; {
            props.impMap.popup.close();
            svModel.create("rectangle");
        });

        const expandTopo = new Expand({
            expandIconClass: "esri-icon-edit",
            view: props.impMap,
            content: graphicsWindow,
            collapseTooltip : "SketchViewModelSample",
            expandTooltip : "SketchViewModelSample"
        });

        props.impMap.ui.add(expandTopo, "top-right");

        svModel.on("create", (event: any) =&amp;gt; {
            if (event.state === "complete") {
                alert("Draw completed in SketchViewModelSample !!");
            }
        });

    }, []);

    return (
        &amp;lt;React.Fragment&amp;gt;
            &amp;lt;div id="drawGraphicsWindow"&amp;gt;
                &amp;lt;div
                    id="create-by-rectangle"
                    className="esri-widget esri-widget--button esri-widget esri-interactive"
                    title="Draw Rectangle"
                &amp;gt;
                    &amp;lt;span className="esri-icon-checkbox-unchecked" /&amp;gt;
                &amp;lt;/div&amp;gt;
            &amp;lt;/div&amp;gt;
        &amp;lt;/React.Fragment&amp;gt;
    )
}

export default SketchViewModelSample;​&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Oct 2022 15:48:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1226653#M79163</guid>
      <dc:creator>AbdulSamim</dc:creator>
      <dc:date>2022-10-28T15:48:30Z</dc:date>
    </item>
    <item>
      <title>Re: Measurement , Sketch and SketchViewModel graphics not showing up in "@arcgis/core": "^4.24.7"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1226682#M79164</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/133686"&gt;@AbdulSamim&lt;/a&gt; check to see if you have .wasm configured in your local webserver: &lt;A href="https://developers.arcgis.com/javascript/latest/install-and-set-up/#web-server-hosting-configuration" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/install-and-set-up/#web-server-hosting-configuration&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Oct 2022 17:07:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1226682#M79164</guid>
      <dc:creator>AndyGup</dc:creator>
      <dc:date>2022-10-28T17:07:53Z</dc:date>
    </item>
    <item>
      <title>Re: Measurement , Sketch and SketchViewModel graphics not showing up in "@arcgis/core": "^4.24.7"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1226938#M79168</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/180"&gt;@AndyGup&lt;/a&gt;&amp;nbsp;, just confirm you I am not hosted&amp;nbsp;&lt;SPAN&gt;the ArcGIS API for JavaScript instead of that &amp;nbsp;managing the assets&amp;nbsp;&amp;nbsp;locally through help of below URL.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/es-modules/#managing-assets-locally" target="_blank" rel="noopener"&gt;https://developers.arcgis.com/javascript/latest/es-modules/#managing-assets-locally&lt;/A&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;After following the steps in above URL, under &lt;STRONG&gt;public&lt;/STRONG&gt; folder of my project components and esri subfolders are created successfully.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_0-1667190337124.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54787i881B58A260B4F2A7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AbdulSamim_0-1667190337124.png" alt="AbdulSamim_0-1667190337124.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As I mentioned earlier in my query esri sketch, sketch view model and measurement widget graphics are not showing up while using&amp;nbsp;"@arcgis/core": "^4.24.7".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_0-1667191051158.png" style="width: 775px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54788i3656F400B03704AD/image-dimensions/775x31?v=v2" width="775" height="31" role="button" title="AbdulSamim_0-1667191051158.png" alt="AbdulSamim_0-1667191051158.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AbdulSamim_1-1667191134454.png" style="width: 768px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54789iD31062B355680362/image-dimensions/768x77?v=v2" width="768" height="77" role="button" title="AbdulSamim_1-1667191134454.png" alt="AbdulSamim_1-1667191134454.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 31 Oct 2022 04:39:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1226938#M79168</guid>
      <dc:creator>AbdulSamim</dc:creator>
      <dc:date>2022-10-31T04:39:55Z</dc:date>
    </item>
    <item>
      <title>Re: Measurement , Sketch and SketchViewModel graphics not showing up in "@arcgis/core": "^4.24.7"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1227088#M79179</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/133686"&gt;@AbdulSamim&lt;/a&gt;&amp;nbsp; these types of errors are typically related to project configuration, and not a bug in the ArcGIS JS API. Please provide a link to a simple github repository that reproduces the issue.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 31 Oct 2022 16:36:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/measurement-sketch-and-sketchviewmodel-graphics/m-p/1227088#M79179</guid>
      <dc:creator>AndyGup</dc:creator>
      <dc:date>2022-10-31T16:36:44Z</dc:date>
    </item>
  </channel>
</rss>

