Closed
Description
Reproduction
https://stackblitz.com/edit/mat-tree-flat-data-source-bug?file=src/app/tree-flat-overview-example.ts
Steps to reproduce:
- Try to initialize the data in the constructor
- Run the app
Expected Behavior
The MatTreeFlatDataSource
accepts an optional argument initialData
. I would expect the data sorce to be properly initialized when set in the constructor.
Actual Behavior
Tree renders as if data is empty
Environment
- Angular: 11
- CDK/Material: 11
- Browser(s): latest chrome
- Operating System (e.g. Windows, macOS, Ubuntu): windows