Hi!
I have a problem using a secured feature service.
esriConfig.request.interceptors.push({
urls: FeatureLayerURL,
before: function(params) {
params.requestOptions.query = params.requestOptions.query || {};
params.requestOptions.query.token = token;
},
});
the code does work until I try to Edit features(using EditorViewModel) and then the portal login screen popup appear.
Solved! Go to Solution.
Found a better solution, I used this code:
esriId.registerToken({
server: FeatureLayerURL,
token: token
})
esriID is from the library "esri/identity/IdentityManager"
Found a better solution, I used this code:
esriId.registerToken({
server: FeatureLayerURL,
token: token
})
esriID is from the library "esri/identity/IdentityManager"