onEnterDOM or onBeforeRendering for custom webcomponent #6929
Replies: 1 comment
-
Hello @akshilverma
|
Beta Was this translation helpful? Give feedback.
-
Hello @akshilverma
|
Beta Was this translation helpful? Give feedback.
-
Hi,
I have created a custom webcomponent package using ui5-webcomponents documentation. I have a scenario where I pass some data in an event and this data can be passed back to the custom component when rendering it. I am reading this data in the onEnterDOM lifecycle hook of the webcomponent.
When the webcomponent is consumed in a React app, this seems to work fine. But when I am trying to consume the webcomponent in Angular, the data is not getting updated in the onEnterDOM hook. If I change my logic to run in the onBeforeRendering, the data is updated.
My doubt is which of the lifecycle hooks is the correct way of reading passed data?
Best regards,
Akshil Verma
Beta Was this translation helpful? Give feedback.
All reactions