I want to show different types of CimSymbol (images) in a FeatureLayer ( because i want to cluster them.) based on the source data i receive from my back-end. How can i achieve this ?
const layer = new FeatureLayer({
renderer: {
type: "simple",
symbol: {
type: "cim",
data: {} // dynamic data based on data in source
},
},
title: "Orders",
objectIdField: "ObjectID",
source: [] // dynamic data with orders with different types of location
});
Hi @KeremDenizmen - have you considered using UniqueValueRenderer? This will allow you to symbolize your features based on categorical attributes. You could use a different CIMSymbol for each category, for example.
It also sounds like you might want to create a FeatureLayer from client-side features - I'd recommend checking out the documentation on creating a FeatureLayer here (specifically look at the section called "Add an array of client-side features"): https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-FeatureLayer.html#creating...