angular mat tables pagination not working for dynamic tables code example
Example: settign datasource to paginator only works with setTimeout
@ViewChild(MatSort) set matSort(sort: MatSort) {
this.dataSource.sort = sort;
}
@ViewChild(MatSort) set matSort(sort: MatSort) {
this.dataSource.sort = sort;
}