I'm using Javascript api 4.31 and am getting Property 'geometry' does not exist error when trying to create a graphic from a point. My code is this:
// First create a point geometry let point = { type: "point", // autocasts as new Point() longitude: -71.2643, latitude: 42.0909 }; // Create a symbol for drawing the point let markerSymbol = { type: "simple-marker", // autocasts as new SimpleMarkerSymbol() color: [226, 119, 40] }; // Create a graphic and add the geometry and symbol to it let pointGraphic = new Graphic({ geometry: point, symbol: markerSymbol });
Solved! Go to Solution.
thanks Wesley -- thats it