I need to load a component at loading
<app-main id="tasks" [(ngModel)]="tasks"></app-main>
And the call from js
public tasks;
ngOnInit() {
this.tasks.click();
}
I have tryed document.getElementById("tasks").click() and ngAfterViewInit()