Hello everyone, I am currently facing some issues retrieving my Feature Layer from the server directory. I am currently using ArcGIS API for JavaScript 3.41.
I have tried the following code however, there are some issues in retrieving the information I need. For eg. there are a few missing properties such as the id, info template, _fields within the layer itself.
Below are the 2 methods I have tried I am able to retrieve the layers however the properties are still undefined or empty. Am I missing any steps?
const layer = new FeatureLayer({ "sampleserver6.arcgisonline.com/arcgis/rest/services/USA/MapServer/0" });
var flayer = new FeatureLayer({
portalItem: {
id: item._id
}
});