[Sidenav] Memory leak when used inside router-outlet
- Ngôn ngữ chính
- TypeScript
- Star
- 25k
- Fork
- 6.8k
- Merge trung bình
- 1 ngày 8 giờ
- Pull request đã merge (30 ngày)
- 91
Mô tả
#### Bug, feature request, or proposal:
When a sidenav is used "inside" router-outlet, it seems there is a memory leak. When the router-outlet is inside the sidenav, there is no problem.
I use the "Take heap snapshot" of Chrome to see the problem.
#### What are the steps to reproduce?
Sample available on:
https://stackblitz.com/edit/angular-material2-issue-xmgukp?file=app%2Fapp.component.ts
Open in Chrome:
https://angular-material2-issue-xmgukp.stackblitz.io/
- Switch between "one" and "two" routes a few times.
- Take a heap snapshot
- Switch again between routes
- Take another snapshot and compare => OneComponent and TwoComponent are not freed (among many other objects...)
Hướng dẫn đóng góp
Hướng nghiên cứu
Bắt đầu với bản tái hiện StackBlitz được liên kết và tái hiện hiện tượng rò rỉ bằng cách chuyển đổi giữa các route one và two bên trong sidenav. So sánh các heap snapshot của Chrome trước và sau các lần chuyển đổi bổ sung; được xem là hoàn tất khi OneComponent và TwoComponent, cùng với các đối tượng liên quan, được giải phóng thay vì bị giữ lại.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- angular, typescript
- Lĩnh vực
- frontend, performance
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100