I have a dynamically created component inside an *ngFor and how do I get the offsettop and offsetleft for those after getting them in a ViewChildren.
Template
<anchor #myanchor></anchor>
Class
@ViewChildren('myanchor') anchors: QueryList<any>;
Here is the ngAfterViewInit
ngAfterViewInit(){
this.anchors.map(i=>{ console.log(i); })
}
I am able to get the position for a single element through ViewChild but need help with ViewChildren. Any pointers will be appreciated.