Hi all,
I am in the process of migrating from 4.15 to 4.16 API and face a lot of problems.
It looks like when you instantiate a widget in the afterCreate function within the renderer, the created widget doesn't get initialised properly. The postInitialize of the (custom) widget executes in a later phase, not right after the new CustomWidget statement.
This is a huge difference with 4.15 and makes a lot of our code become useless.
Can someone from Esri confirm this difference or give me a clue how to do it correct?
Thanks in advance!
Example:
render() {
return <div>
<div afterCreate={this.createWidget} bind={this}></div>
</div>
}
private createWidget(node: HTMLDivElement) {
const w = new CustomWidget({
container: node,
view: this.view
});
// At this point the widget postInitialize is not executed, in 4.15 it was.
}