|
POST
|
The interceptors only work when using the request method of the JSAPI. https://developers.arcgis.com/javascript/latest/api-reference/esri-request.html It uses fetch under the hood, but can't intercept native fetch requests.
... View more
09-29-2022
10:58 AM
|
2
|
1
|
3132
|
|
POST
|
Not sure. Do you have a codepen or github showing the issue? Using your code here with some values and seems to work, could be something else. https://codepen.io/odoe/pen/wvjyxvj?editors=1000
... View more
09-28-2022
03:15 PM
|
0
|
0
|
2550
|
|
POST
|
@RiccardoKlinger you're very close. You just need to adjust your handler declaration and how you handle it a bit. https://codepen.io/odoe/pen/bGMaJPW?editors=1001 let handler;
function myChange() {
if (document.getElementById("check").checked) {
// check if null
if (handler) {
return;
}
handler = view.on("click", (event) => {
const point = `point: (${event.mapPoint.latitude}, ${event.mapPoint.longitude})`;
console.log(point);
});
} else {
// remove and set to null
handler?.remove();
handler = null;
}
}
... View more
09-27-2022
01:36 PM
|
0
|
0
|
4489
|
|
POST
|
The ".on()" methods in the API return a Handler with a remove method you can use to remove the listener. let handler;
handler = view.on("click", () => {
console.log("click");
handler && handler.remove();
}); Looks like something happened to the doc on this. I'll pass it on, thanks! Looks like it's not a specific type, it's just an Object with a remove() method as described here. https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#on
... View more
09-27-2022
11:10 AM
|
0
|
2
|
4521
|
|
POST
|
If you have a sample repro in codepen or github, would be helpful to track down the issue. This sample works as expected when the popup closes via view.popup.close() https://codepen.io/odoe/pen/LYmOwvY?editors=100
... View more
09-26-2022
08:27 AM
|
0
|
0
|
1517
|
|
POST
|
Not sure I understand the context. Calcite Components is a UI component library, it doesn't have any specific connection to arcgis services. The Editor widget uses Calcite Components.
... View more
09-23-2022
10:35 AM
|
0
|
0
|
735
|
|
POST
|
If you open the developer tools in your browser, are you getting any particular errors? Is you webmap public?
... View more
09-23-2022
07:18 AM
|
0
|
0
|
3760
|
|
POST
|
You have a couple of spots where you're passing a layer, but it's not defined. if (layer.title === "Entire Structure") {
EntireStructureLayer = {
layer: EntireStructure, // EntireStructure undefined
if(layer.title === "DamagedAreasmultipatch") // missing {} too
DamagedAreasLayer = {
layer: DamagedAreasmultipatch, // DamagedAreasmultipatch undefined In those cases, if the title matches, you can just pass the layer instance for the editor to use.
... View more
09-20-2022
08:01 AM
|
0
|
1
|
3558
|
|
POST
|
You can try watching the layerView updating property. https://developers.arcgis.com/javascript/latest/api-reference/esri-core-reactiveUtils.html#whenOnce view.when(async () => {
const layerView = await view.whenLayerView(layer);
await whenOnce(
() => !layerView.updating
);
console.log("map image layer done drawing");
}); You could wait for view.updating too, it's based off the child layerviews updating property.
... View more
09-13-2022
07:53 PM
|
0
|
1
|
1450
|
|
POST
|
Default values can only be set when publishing the services. Adding default values via the Editor widget is not supported.
... View more
09-09-2022
07:27 AM
|
0
|
0
|
1635
|
|
POST
|
Ah, sorry. That won't work in 4.13. That was introduced at 4.23 I think. Before that, we didn't have that option in the IdentifyParameters like in 3x. In recent 4x version, the sublayers need to come from a MapImageLayer as they need a layer source. https://codepen.io/odoe/pen/qBYbOyG?editors=1000
... View more
09-07-2022
04:00 PM
|
1
|
0
|
2509
|
|
POST
|
You can define the defintionExpression in a sublayer in the IdentifyParameters https://developers.arcgis.com/javascript/latest/api-reference/esri-rest-support-IdentifyParameters.html#sublayers You can create a MapImageLayer with your sublayers, load it, then add those sublayers to the parameters. https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-Sublayer.html#source
... View more
09-07-2022
01:23 PM
|
0
|
0
|
2576
|
|
POST
|
I have tried a bunch of variations of of this and cannot replicate this behavior. If you provide a codepen or simplified github sample, could better help, but not sure otherwise.
... View more
09-06-2022
08:25 AM
|
0
|
0
|
1426
|
|
POST
|
The JSAPI isn't open-source, so we don't provide the unminified code anywhere. We only have custom layer extensibility for Tiled layers, not FeatureLayers. We also have request interceptors, where you can modify the response before the layers use it, but no guarantee we don't use the service defined fields for other parts of the drawing and query stuff, you might be able to do some stuff here, but you're just adding to query time here too by pulling in new data requests. https://developers.arcgis.com/javascript/latest/api-reference/esri-config.html#RequestInterceptor If you have Enterprise portal, you can do this via a SOE. Doing this on the client is probably going to require a custom worker one way or another
... View more
09-05-2022
09:39 AM
|
0
|
1
|
1870
|
|
POST
|
At a glance, it doesn't look like you are adding the layer to the FeatureTable. Would need a simpler codepen or similar if that doesn't fix it.
... View more
09-05-2022
09:30 AM
|
0
|
1
|
852
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 3 weeks ago | |
| 2 | 3 weeks ago | |
| 1 | 02-27-2026 06:31 AM | |
| 1 | 01-13-2026 02:15 PM | |
| 1 | 12-31-2025 09:05 AM |
| Online Status |
Offline
|
| Date Last Visited |
2 weeks ago
|