Created
May 22, 2018 18:35
-
-
Save daniele-zurico/09288f8841b47ef3e73ec184656e3273 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="mat-elevation-z8"> | |
<mat-table #table [dataSource]="dataSource" matSort aria-label="Elements"> | |
<ng-container [matColumnDef]="cols" *ngFor="let cols of displayedColumns"> | |
<mat-header-cell *matHeaderCellDef mat-sort-header> {{cols}} </mat-header-cell> | |
<mat-cell *matCellDef="let element"> {{element[cols]}} </mat-cell> | |
</ng-container> | |
<mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row> | |
<mat-row *matRowDef="let row; columns: displayedColumns;"></mat-row> | |
</mat-table> | |
<mat-paginator #paginator | |
[length]="dataSource.data.length" | |
[pageIndex]="0" | |
[pageSize]="50" | |
[pageSizeOptions]="[25, 50, 100, 250]"> | |
</mat-paginator> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment