From 5eac621ac5712451a6d598a8c8b78082df9e4d25 Mon Sep 17 00:00:00 2001 From: Eugene Pankov Date: Sat, 3 Jun 2017 15:07:42 +0200 Subject: [PATCH] Revert "Revert "."" This reverts commit fd67a3c69747aff8f09c598093328ff4e0249703. --- .../components/settingsTabBody.component.ts | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/terminus-settings/src/components/settingsTabBody.component.ts b/terminus-settings/src/components/settingsTabBody.component.ts index c3b6e519..2616617a 100644 --- a/terminus-settings/src/components/settingsTabBody.component.ts +++ b/terminus-settings/src/components/settingsTabBody.component.ts @@ -1,25 +1,10 @@ -import { Component, Input, ViewContainerRef, ViewChild, ComponentFactoryResolver, ComponentRef } from '@angular/core' +import { Component, Input } from '@angular/core' import { SettingsTabProvider } from '../api' @Component({ selector: 'settings-tab-body', - template: '', + template: '', }) export class SettingsTabBodyComponent { @Input() provider: SettingsTabProvider - @ViewChild('placeholder', {read: ViewContainerRef}) placeholder: ViewContainerRef - private component: ComponentRef - - constructor (private componentFactoryResolver: ComponentFactoryResolver) { } - - ngAfterViewInit () { - // run after the change detection finishes - setImmediate(() => { - this.component = this.placeholder.createComponent( - this.componentFactoryResolver.resolveComponentFactory( - this.provider.getComponentType() - ) - ) - }) - } }