The <mat-table> provides a styled data-table and it can be used for display rows of the data . For more detail - https://material.angular.io/cdk/table/overview Its looks like - < mat-table [ dataSource ]= ”myDataArray” > ... </ mat-table > The example for used < data-table > and display records as following – data-table.ts – import { Component } from '@angular/core' ; /* Data-Table Basic Example */ @ Component ({ selector : 'data-table' , styleUrls : [ 'data-table.css' ], templateUrl : 'data-table.html' , }) export class DataTable { displayedColumns = [ 'position' , 'name' , 'weight' , 'symbol' ]; dataSource = MY_USER_DATA ; } export interface User { name : string ; position : number ; weight : number ; symbol : string ; } const MY_USER_DATA : User [] = [ { position : 101 , name : 'A...
Angular, React, JavaScript, Java, PHP, SQL, C#, Vue, NodeJs, TypeScript and Interview Questions Answers