The Selection controller allows you to listen for changes to the selection on the map.
getSelection():
Promise
<EntityNode
[]>
Gets the current selection as a list of entity identifiers.
Returns
Promise
<EntityNode
[]>
Example
onSelectionChange(
params
: {handler
: (change
: {selection
:EntityNode
[]; }) =>void
; }):VoidFunction
Adds a listener for when the selection changes.
Parameters
Returns
VoidFunction
A function to unsubscribe from the listener
Example
Parameter | Type |
---|---|
params
object
params.handler
(change
: {selection
: EntityNode
[]; }) => void