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

内存泄露 #2323

Closed
eightHundreds opened this issue Jul 26, 2023 · 2 comments
Closed

内存泄露 #2323

eightHundreds opened this issue Jul 26, 2023 · 2 comments
Assignees
Labels
help wanted Extra attention is needed / 老铁,赚 PR 的机会来了

Comments

@eightHundreds
Copy link
Contributor

是大纲插件问题

复现

疯狂切换大纲树。投放感应区没正确清理(webpack://AliLowCodeEngine/designer/src/designer/dragon.ts)

2023-07-26 16 55 47

@eightHundreds
Copy link
Contributor Author

eightHundreds commented Jul 26, 2023

应该是在useState初值去构造对象, 因为渲染弄出了很多实例

const [masterPaneController, setMasterPaneController] = useState(new PaneController(props.paneName || MasterPaneName, treeMaster));

PS: 在构造函数(PaneController)中写对外有副作用的逻辑很危险。

@JackLian JackLian added the help wanted Extra attention is needed / 老铁,赚 PR 的机会来了 label Jul 27, 2023
@github-actions
Copy link

Hello @eightHundreds. We totally like your proposal/feedback, PR wanted。

你好 @eightHundreds,我们完全同意你的提议/反馈,欢迎 PR。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed / 老铁,赚 PR 的机会来了
Projects
None yet
Development

No branches or pull requests

3 participants