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

请问什么情况下 会出现两个视图 ,并且第一个视图是空白的,也会占高度。第二个视图,然后高度是变成自动的 #4184

Closed
xssj28 opened this issue Sep 30, 2022 · 4 comments

Comments

@xssj28
Copy link

xssj28 commented Sep 30, 2022

image
image

@hustcc
Copy link
Member

hustcc commented Oct 11, 2022

应该是业务代码中,导致创建了两个 Chart 实例。

@wangmin0314
Copy link

解决了吗?怎么解决的?

@hustcc
Copy link
Member

hustcc commented Oct 26, 2022

可以发一下核心代码吗?只能盲猜是 React 中没有使用 useRef 导致多次创建实例。

@lxliang912
Copy link

每次更新内容前可以考虑是否需求进行clear操作,避免重新创建视图,或者在销毁组件前destroy图表

@hustcc hustcc closed this as completed Dec 6, 2022
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

4 participants