Select to view content in your preferred language

Event on change extent

494
1
01-30-2023 04:16 AM
ADITYAKUMAR1
Frequent Contributor

Hi ,

   I am trying to plot the cluster based on the zoom levels. But this is done while changing the map extent.

reactiveUtils.when(
() => this.map.mapView.stationary === true,
() => {
if (this.map.mapView.extent) {
this.myfunction();
}
}
);

The event is working on the change extent but on calling my function I am getting a different error.

ADITYAKUMAR1_0-1675080787245.pngADITYAKUMAR1_1-1675080817433.png

Uncaught (in promise) l {name: 'AbortError', details: undefined, message: 'Aborted'}

Any idea why this error is appearing? 

Thanks

Aditya kumar

Tags (1)
0 Kudos
1 Reply
ReneRubalcava
Honored Contributor

Not able to replicate in the samples or a codepen, so I think it's going to depend on what this.myfunction() is doing. You might be trying to access properties that are still changing, or maybe something with the view. If you can provide a repro demo in codepen or github, could have a better idea.

0 Kudos