2

I have a table with 100+ rows and dynamic columns.

<tr mat-header-row *matHeaderRowDef = "displayColumns; sticky: true"> </ tr>
<tr mat-row * matRowDef = "let row; columns: displayColumns"> </ tr>

Thus, if I change the displayColumns, angular will re-render the entire table(3+ sec). Is there a solution for optimizing it? Or should I use display: hidden for this?

And how can I animate the addition of columns?

Gregor Albert
  • 819
  • 1
  • 11
  • 23
  • Are you using pagination for your table? If yes, then have a look at [this](https://stackoverflow.com/a/51296374/4606040) answer to a similar question. My table also took a few seconds to load (6k rows), but after I implemented the change suggested, it loaded instantly. – Fabian Küng Feb 20 '19 at 07:24

0 Answers0