简体   繁体   中英

How to convert HTML table to angular material table (mat-table)?

I have new to Angular Material and trying to convert basic Angular table to Angular material table using mat-table

I am not sure where to start from. How can I convert below table to mat-table?

Here is my.html file which contains table

 <div> <h2>Count Data</h2> <ng-container> <table style = 'width: 50%;'> <tr> <td>Select 1 {{newFinal.color}}</td> <td>{{newFinal.zind}}</td> </tr> <tr> <td colspan = '3' class = 'bold'> Wasi Final: {{newFinal.Queue}} ({{newFinal.selection}}) </td> </tr> <tr> <td colspan = '3' class = 'bold'> Collar Final: ({{newFinal.Titir}}) </td> </tr> </table> </ng-container> </div>

https://material.angular.io/components/table/overview

the doc is amazing and full of example

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM