How to know when the component is loaded?

假装没事ソ 提交于 2019-12-23 04:04:38

问题


When creating a AngularDart component, I can use ShadowRootAware and override onShadowRoot to be sure that the shadow dom is loaded and ready for manipulation, as described by the docs;

It is guaranteed that when [onShadowRoot] is invoked, that shadow DOM has been loaded and is ready.

However, if useShadowDom is set to false, what alternative do I have that guarantees that the component or its content is loaded and ready to be manipulated?


回答1:


You can use the same approach. Even though it says onShadowRoot it's still fired when it should with shadow root disabled. We just tried this last week on v0.12



来源:https://stackoverflow.com/questions/24470496/how-to-know-when-the-component-is-loaded

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!