首页 > 解决方案 > 在包装表中使用 Angular Material 表 mat-text-column

问题描述

我正在使用 Angular Material 表,并且构建了一个像https://github.com/angular/components/tree/master/src/material-examples/table-wrapped这样的包装表。有什么办法可以mat-text-column在我包裹的桌子上吗?当我执行以下操作时:

<wrapper-table [dataSource]="dataSource" [columns]="displayedColumns" matSort #sort="matSort">
    <mat-text-column name="firstName"></mat-text-column>
</wrapper-table>

我明白了Error: Could not find column with id "firstName".

标签: angularangular-material2angular-componentsangular-material-table

解决方案


推荐阅读