X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=client%2Fsrc%2Fapp%2F%2Bhome%2Fhome.component.ts;h=f966a2b024e11626183f81946107f54ca1798eee;hb=22f25c740bf3eb24d9988ab6add8e1a6aec1b0bd;hp=16d3a6df7cc6a405650d48de40098fbbad662498;hpb=8f608a4cb22ab232cfab20665050764b38bac9c7;p=github%2FChocobozzz%2FPeerTube.git diff --git a/client/src/app/+home/home.component.ts b/client/src/app/+home/home.component.ts index 16d3a6df7..f966a2b02 100644 --- a/client/src/app/+home/home.component.ts +++ b/client/src/app/+home/home.component.ts @@ -1,6 +1,4 @@ - import { Component, ElementRef, OnInit, ViewChild } from '@angular/core' -import { CustomMarkupService } from '@app/shared/shared-custom-markup' import { CustomPageService } from '@app/shared/shared-main/custom-page' @Component({ @@ -11,16 +9,14 @@ import { CustomPageService } from '@app/shared/shared-main/custom-page' export class HomeComponent implements OnInit { @ViewChild('contentWrapper') contentWrapper: ElementRef + homepageContent: string + constructor ( - private customMarkupService: CustomMarkupService, private customPageService: CustomPageService ) { } - async ngOnInit () { + ngOnInit () { this.customPageService.getInstanceHomepage() - .subscribe(async ({ content }) => { - const element = await this.customMarkupService.buildElement(content) - this.contentWrapper.nativeElement.appendChild(element) - }) + .subscribe(({ content }) => this.homepageContent = content) } }