primereact
primereact copied to clipboard
DataTable Virtual Scroll: Memory leak when data updated continuously
Describe the bug
var viewInit = function viewInit() {
if (elementRef.current && DomHandler.isVisible(elementRef.current)) {
setContentElement(_contentRef.current);
init();
// bindWindowResizeListener();
// bindOrientationChangeListener();
defaultWidth.current = DomHandler.getWidth(elementRef.current);
defaultHeight.current = DomHandler.getHeight(elementRef.current);
defaultContentWidth.current = DomHandler.getWidth(_contentRef.current);
defaultContentHeight.current = DomHandler.getHeight(_contentRef.current);
}
};
when I comment bindWindowResizeListener and bindOrientationChangeListener fix memory leak problem
Reproducer
No response
System Information
"primereact": "10.7.0",
"react": "^18.2.0",
Steps to reproduce the behavior
No response
Expected behavior
No response
Thanks for the investigation I assigned to PrimeTek to review.
This issue has been automatically marked as stale. If this issue is still affecting you with the latest version, please leave any comment, and we will keep it open. We are sorry that we have not been able to prioritize it yet. If you have any new additional information, please include it with your comment!
Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please create a new issue with up-to-date information. Thank you for your understanding!