-
Notifications
You must be signed in to change notification settings - Fork 727
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
[BUG] Table+virtualized在快速切换下会触发 Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops #2592
Open
1 task done
Comments
我也能触发这个问题,设置virtualized={false}也一样能触发,stack都是下面这样
简单断点debug了一下,在这行判断,
里面的 stateCachedColumns !== prevState.cachedColumns 始终是true,导致了循环更新 |
你也是用的 jsx children ? |
@shijiatongxue , I used below codes
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is there an existing issue for this?
Which Component
Table
Semi Version
2.69.2
Current Behavior
快速切换页面,重新赋值数据源,有高概率触发
如果去除virtualized则没有任何问题
我用固定的数据源测试也是会这样
然后我发现如果columns不用children传入而是用props传入就不会触发,不过我感觉虽然有关系但不是主要原因,只是因为children传入要计算量比props传入的大,一起造成的原因
Expected Behavior
No response
Steps To Reproduce
No response
ReproducibleCode
No response
Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: