Dynamically renders heatmaps on point layers. For usage in CMV (v1.3.4) with sublayer menu option on the LayerControl. Credit to @ERS-Long
- Layer must be type point
- Layer must have a field of type
esriFieldTypeGeometry
//layerControl widget options:
subLayerMenu: {
dynamic: [{
label: 'Toggle Heatmap...',
iconClass: 'fa fa-fire fa-fw',
topic: 'heatMap'
}]
}
//widget config
heatmap: {
include: true,
id: 'heatmap',
type: 'invisible',
path: 'gis/widgets/HeatMap',
options: {
map: true
}
}
Widget developers can use this widget by publishing the following topic: LayerControl/heatMap
and passing the correct parameters.
topic.publish('LayerControl/heatMap', {
layer: dynamicMapServiceLayer,
subLayer: dynamicMapServiceSubLayer,
iconNode: optionalIconDomNode
});