VisActor / VisActor/VTable

[Bug]在vue2项目中二次封装该组件进行使用出现内存泄漏情况

Open
#4,827 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
TypeScript
Stars
3.7k
Forks
486
Avg merge
1d 19h
Merged PRs (30d)
16

Description

Version

1.22.7

Link to Minimal Reproduction

现无,但是采用其他表格组件如vex-table未发生此种现象

Steps to Reproduce

1.用vue2项目引入该组件,进行二次封装,用VTable.ListTable创建表格实例,值配置基础的行、数据、容器自适应,销毁方法中有销毁实例的。
2.在其他页面引用该二次封装的组件
3.运行项目打开该页面后,先录制内存快照,页面什么都不操作,等待十几二十分钟后,发现内存一直呈现增加趋势。
附上快照截图以及排查的增加的数据发现是组件内部的方法产出的垃圾:

Image Image 不知道是否是内部的progress方法有问题
Current Behavior

使用该组件时内存一直增加,

Expected Behavior

页面引用该组件时内存能正常回收

Environment
- OS:Window10
- Browser:Chrome 96.0.4664.55
- Framework:Vue@2
Any additional comments?

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Vue 2 integration that creates a VTable.ListTable and calls its destroy method, then reproduce the report using Chrome memory snapshots. Inspect the suspected internal progress method and compare retained objects before and after leaving the page. Done means the component's memory is reclaimed after destruction during the reported idle period.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.