- private async buildElement () {
- const element = await this.customMarkupService.buildElement(this.content)
- this.contentWrapper.nativeElement.appendChild(element)
+ private async rebuild () {
+ if (this.content instanceof HTMLDivElement) {
+ return this.loadElement(this.content)
+ }
+
+ const { rootElement, componentsLoaded } = await this.customMarkupService.buildElement(this.content)
+ await componentsLoaded
+
+ return this.loadElement(rootElement)