()
| 989 | @ViewChild(MatPaginator) paginator!: MatPaginator; |
| 990 | |
| 991 | constructor() { |
| 992 | this.underlyingDataSource.data = []; |
| 993 | |
| 994 | // Add three rows of data |
| 995 | this.underlyingDataSource.addData(); |
| 996 | this.underlyingDataSource.addData(); |
| 997 | this.underlyingDataSource.addData(); |
| 998 | |
| 999 | this.underlyingDataSource.connect().subscribe(data => { |
| 1000 | this.dataSource.data = data; |
| 1001 | }); |
| 1002 | } |
| 1003 | |
| 1004 | ngOnInit() { |
| 1005 | this.dataSource!.paginator = this.paginator; |