|
POST
|
Hi there, So it looks like blob field is not working with Labels. Likely will not work in different places. You need to intercept the geojson data after it is fetched and then set up the data in a way where you are not creating object fields... I updated the codepen to showcase this and you will need to modify to meet your needs. https://codepen.io/U_B_U/pen/oNMozyJ?editors=0010 In this codepen, I set the fields schema in the geojson layer constructor. The geojson data is intercepted after it is fetched. Then the app loops through the geojson features, directly store the object properties at the feature.properties level then delete the object properties. Hope this helps. -Undral
... View more
01-24-2023
08:09 AM
|
2
|
1
|
5455
|
|
POST
|
Please see my response here: https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-can-i-get-layerid-in-experience-builder/m-p/1249948/highlight/true#M79975
... View more
01-20-2023
08:37 AM
|
1
|
0
|
5411
|
|
POST
|
We are at version 4.25! 4.2 version is retired and we no longer support it. Is there a reason why you are using such old version?
... View more
01-20-2023
08:33 AM
|
0
|
1
|
2021
|
|
POST
|
Hi there, So I tried my best to understand what problem you are trying to solve. I apologize if I did not understand the issue you are trying to solve. Seems like you want to display popupTemplate for only selected layers when user moves the mouse over the map? At least I think this is what you are asking. Displaying popupTemplate from pointer-move is intense. So I suggest you use debounce method to improve the app performance. The MapView.hittest method lets you specify which layers you want to include in the hittest result. So you can specify the layers there. This way the hittest will return results only for those layers. You can also set the exclude to specify layers to be excluded from the hittest. Hope this helps! The following codepen app displays popupTemplate from pointer-move event. It uses include parameter to specify to only include cities feature layer to be included in the hittest. It also uses debounce for the hittest so you can "debounce", or cancel the function execution, until the previous execution of the same function call finishes. https://codepen.io/U_B_U/pen/KKBZmzq?editors=1000
... View more
01-20-2023
08:31 AM
|
1
|
1
|
3660
|
|
POST
|
Hi there, Which version of the API are you using? Can you please share one of the icons being used?
... View more
01-20-2023
07:56 AM
|
0
|
1
|
2028
|
|
POST
|
HI there, I just tested your code snippet with JS API version 4.25 and was not able to reproduce the behavior you described. Here is the codepen: https://codepen.io/U_B_U/pen/OJOVKyP?editors=1000
... View more
01-20-2023
07:51 AM
|
1
|
0
|
832
|
|
POST
|
@JoelBennett is absolutely right. The code snippet he provided will work. I am adding perhaps the obvious point here. You need to set the fields in the GeoJSONLayer constructor and for the object properties you need to set the field type as blob and the code Joel will work. Here is a very simple test app that uses the geojson you provided and the code Joel provided. https://codepen.io/U_B_U/pen/oNMozyJ?editors=0010
... View more
01-18-2023
12:28 PM
|
2
|
1
|
5519
|
|
POST
|
Hi there, Sounds like you are running into a behavior described here: https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/aborterror-when-deleting-a-layer-after-changing/m-p/1242399/highlight/true#M79671 This issue will be fixed at version 4.26. In meantime, you can test the fix on our next release by the end of this week by pointing your app to: <script src="https://js.arcgis.com/next/"></script> I was not able to reproduce the issue in 4.25. But I did test your codepen using next and did not see the abortError.
... View more
01-17-2023
08:22 AM
|
1
|
2
|
2989
|
|
POST
|
Hi there, As you pointed out that the only workaround for the behavior you describe is here: https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/clarification-on-4-23-hittest-return-value/m-p/1157887#M76795 We do have plans to support sorting for hittest. But I don't have any dates when this will be implemented. -Undral
... View more
01-17-2023
08:10 AM
|
0
|
1
|
2265
|
|
POST
|
Hi there, Yes we were able to reproduce the issue and I will update you here once we have a fix. Thanks, -Undral
... View more
12-27-2022
09:18 AM
|
0
|
0
|
3843
|
|
POST
|
You can loop through the sublayers once MapImageLayer is loaded into the MapView as shown below: const popupTemplate = {
title: "Common title",
content: "Common content"
};
view.whenLayerView(layer).then(() => {
layer.sublayers.forEach(
(sublayer) => (sublayer.popupTemplate = popupTemplate)
);
});
... View more
12-21-2022
08:56 AM
|
0
|
1
|
1533
|
|
POST
|
Hi there, Thank you for reporting this issue. Let me look into it and I will update you here.
... View more
12-20-2022
08:57 AM
|
0
|
1
|
3891
|
|
POST
|
Hi there, You need to set the popupTemplate on the sublayers as shown here: https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-Sublayer.html#popupTemplate
... View more
12-20-2022
08:09 AM
|
0
|
3
|
1553
|
|
POST
|
Hi there, This sample https://developers.arcgis.com/javascript/latest/sample-code/sandbox/?sample=view-hittest shows you how to do this. Namely take a look at the getGraphics function where we are checking if the some attributes of the graphic returned from hottest matches the attributes of the already highlighted graphic like so: const graphic = response.results[0].graphic;
const attributes = graphic.attributes;
const category = attributes.CAT;
const wind = attributes.WIND_KTS;
const name = attributes.NAME;
const year = attributes.YEAR;
const id = attributes.OBJECTID;
if (highlight && (currentName !== name || currentYear !== year)) {
highlight.remove();
highlight = null;
return;
}
if (highlight) {
return;
}
... View more
12-20-2022
08:04 AM
|
0
|
1
|
1559
|
|
POST
|
We fixed this Issue at 4.26. You can test the fix on our next release by the end of this week by pointing your app to: <script src="https://js.arcgis.com/next/"></script> -Undral
... View more
12-19-2022
08:39 AM
|
0
|
0
|
6461
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 11-17-2025 03:29 PM | |
| 1 | 07-09-2025 08:48 AM | |
| 2 | 07-08-2025 08:09 AM | |
| 2 | 07-07-2025 03:57 PM | |
| 1 | 06-11-2025 03:25 PM |
| Online Status |
Offline
|
| Date Last Visited |
12-01-2025
08:03 AM
|