Closed
Description
Reproduction
https://stackblitz.com/edit/active-item-reference?file=src/app/app.component.html
Steps to reproduce:
- Click 'Fill List'
- Click 'Clear List'
Expected Behavior
It should display the message 'ActiveItem: null', because the activeItem
should be null, when there are no items.
Actual Behavior
It displays the message 'ActiveItem: "0"'.
It has no items, but the activeItem
still contains a reference of a deleted node.
Environment
- Angular: 11.0.4
- CDK/Material: 11.2.4
- Browser(s): Chrome
- Operating System: Windows