Hi,
I need to add feature layer to a map.
My code:
this.props.mapView.map.add(
new FeatureLayer({
url: Config.layerUrl,
token: this.props.token
})
);
Problem 1: TypeScript returns the following error: "'token' does not exist in type 'FeatureLayerProperties'." I checked the type definition @types/arcgis-js-api@4.7.0, it is not defined, but 'token' exists in the documentation: FeatureLayer | API Reference | ArcGIS API for JavaScript 4.7
Ok, I added type for 'token' on my own, but then we have problem 2...
Problem 2: The 'token' will not be sendt to the server. So I get a login dialog to be authenticated.
My question is how to add a featureLayer to the map by using token?