Your listener id (must be unique for all layer events)
Your listener function
// Each time a layer is deleted, will display a message in the console
JMap.Event.Layer.on.layerDeletion(
"custom-layer-deletion",
params => {
console.log(`Layer id="${params.layerId}" has been deleted client side`)
}
)
JMap.Event.Layer.on.layerDeletion
This event is triggered when a layer is deleted.