Hello folks,
I am adding graphs on a view, and they are being added well, but the console keeps showing me the error:
[esri.core.Accessor] Accessor#set Assigning an instance of 'esri.Graphic' which is not a subclass of 'esri.Graphic'
Below is the code:
import Graphic from "@arcgis/core/Graphic";
import Point from "@arcgis/core/geometry/Point";
//{map and view options defined in another component}
function PathDraw( view, myPath) {
const polyline = {
type: "polyline",
paths: myPath,
};
const lineSymbol= {
type: "line-3d",
symbolLayers: [
{
type: "line",
material: { color: "orange" },
size: "2px",
},
},
],
};
const polylineGraph= new Graphic({
geometry: polyline,
symbol: lineSymbol,
});
view.graphics.add(polylineGraph);
}
export default PathDraw
Does anyone has an idea about this? Thanks