user2894816
user2894816

Reputation: 1

Expand All rows in Material Table

This might look like a Repeated question . I am new to angular and I have a functionality where I need to have sub rows to be shown on a table.

I am using material table and found an perfect example which is working. How ever I need an expand All functionality when clicked should expand all rows in the table.

The code I found below opens only one row each time on click. I tried several things but of no use. Any help is appreciated.

https://stackblitz.com/edit/angular-material2-expandable-rows-filter-pagination-sorting?file=app%2Fcdk-detail-row.directive.ts

Upvotes: 0

Views: 1255

Answers (1)

Ashokan Sivapragasam
Ashokan Sivapragasam

Reputation: 2199

Uncommenting the this.render(), works as expected. Find the example here. https://stackblitz.com/edit/angular-material2-expandable-rows-filter-pagination-sort-7u6hee?file=app/cdk-detail-row.directive.ts

Upvotes: 1

Related Questions