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

vue3自定义渲染节点内存泄漏 #4538

Open
Gcgetget opened this issue Dec 24, 2024 · 1 comment
Open

vue3自定义渲染节点内存泄漏 #4538

Gcgetget opened this issue Dec 24, 2024 · 1 comment

Comments

@Gcgetget
Copy link

Gcgetget commented Dec 24, 2024

Describe the bug

使用@antv/x6-vue-shape渲染自定义节点,发生内存泄漏,具体现象如下:
点击销毁节点,后进行内存分析,发现自定义渲染节点Count组件虽然已经销毁,但是变成了dom游离节点,并没有真正销毁。
image
点击销毁后,count组件onUnmounted执行:
image
手动进行垃圾回收后,进行detached elements分析,count组件变成游离节点:
image

代码实现:
App.vue:
image
Count.vue:
image

版本:
"@antv/x6": "1.34.13",
"@antv/x6-vue-shape": "1.5.4",
"vue": "3.5.13",

Your Example Website or App

https://x6.antv.vision/zh/docs/tutorial/advanced/react/#%E6%B8%B2%E6%9F%93-vue-%E8%8A%82%E7%82%B9

Steps to Reproduce the Bug or Issue

详见bug描述

Expected behavior

销毁后,不存在游离节点

Screenshots or Videos

Platform

  • OS: Windows
  • Browser: Chrome
  • Version: 131.0.6778.140

Additional context

No response

@x6-bot
Copy link
Contributor

x6-bot bot commented Dec 24, 2024

👋 @Gcgetget

Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it.
To help make it easier for us to investigate your issue, please follow the contributing guidelines.
We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.

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