Closed timkindberg closed 8 years ago
Add the ability to inject ancestor light dom component controllers into child. See http://blog.thoughtram.io/angular/2015/04/09/developing-a-tabs-component-in-angular-2.html for in-depth example. Here's the gist of it:
@Component({ selector: 'tabs' }) export class Tabs { addTab(tab: Tab) { } } @Component({ selector: 'tab' }) export class Tab { constructor(tabs:Tabs) { // tabs is a reference to the first ancestor Tabs component controller tabs.addTab(this); } }
Add the ability to inject ancestor light dom component controllers into child. See http://blog.thoughtram.io/angular/2015/04/09/developing-a-tabs-component-in-angular-2.html for in-depth example. Here's the gist of it: