Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Memory leak when use virtualized #477

Open
Ashiria7 opened this issue Dec 18, 2023 · 0 comments
Open

Memory leak when use virtualized #477

Ashiria7 opened this issue Dec 18, 2023 · 0 comments

Comments

@Ashiria7
Copy link

Versions

package version
react X.Y.Z
rsuite-table X.Y.Z

What is the expected behavior?

What is the current behavior?

What are the steps to reproduce?

使用文档中的virtualized例子,打开devtool -> memory,不断向下滚动,生成一个内存快照,即可看到大量的已分离Dom对象;
image
目前定位到的代码在

const tableRows = useRef<{ [key: string]: [HTMLElement, any] }>({});

这个对象记录了所有行的Dom对象以及RowData,包括已经卸载的,并且目前看来没有清除的时机,除非整个table卸载

Any additional comments? (optional)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant