I want to respond when the user selects a new basemap. I don’t see any specific events for this. Am I missing one?
I noticed that the reference for the selectedImagery member of BaseLayerPickerViewModel states:
Gets or sets the currently selected imagery. This property is observable.
This suggests I might be able to observe a property change here to get what I want. Using definitonChanged as suggested by the Property reference, I try this:
But this produces an error: Cannot read property ‘addEventListener’ of undefined
It seems I don’t get definitionChanged here. What am I doing wrong?