typescript - How do I extend a class thats using direct injection -
hopefully should relatively easy question of out there... i trying extend component not sure how deal constructor method of new component. below base component import { component, oninit } '@angular/core'; import { controlsservice } '../controls.service' @component({ moduleid : module.id, selector : 'app-base', templateurl : 'base.component.html', styleurls : ['base.component.css'], providers : [controlsservice] }) export class basecomponent implements oninit { constructor(_controlservice:controlsservice) {} ngoninit() { // console.log(this._controlservice.getcontrolbyid('b5ee385d-1d6a-335a-1e94-2f857428a6fb')) } } and below new component import { component, oninit } '@angular/core'; import { mdtoolbar } '@angular2-material/toolbar'; import { mdicon, mdiconregistry} '@angular2-material/icon'; import { panelcomponent } ...