-
Notifications
You must be signed in to change notification settings - Fork 743
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] Chat组件Uncaught runtime errors:ResizeObserver #2384
Comments
我这边官网没有复现你的问题。给个 codesandbox 复现示例?录屏看看详细复现路径 |
代码仓库:https://github.com/algfwq/Semi_worry |
|
+1,我也遇到了这个问题 |
如果 chrome 没有复现可以试试 safari,safari 可以稳定复现 |
问题原因: 因此最小的复现案例是使用 create-react-app 生成的 webpack 项目中,使用 autoSize API 的 TextArea
使用了 autosize 属性的 TextArea 中有用到 ResizeObserver 监听 高度变化时候,会触发 ResizeObserver 的 onResize 调用,调用的函数链中有 https://github.com/DouyinFE/semi-design/blob/v2.72.0/packages/semi-foundation/input/textareaFoundation.ts#L197 语句,导致在开发中报错ResizeObserver loop completed with undelivered notifications。 问题的影响范围 是否需要修改? |
Is there an existing issue for this?
Which Component
Chat
Semi Version
2.63.1
Current Behavior
运行官网的演示代码,出现的报错:

Uncaught runtime errors:
×
ERROR
ResizeObserver loop completed with undelivered notifications.
at handleError (http://localhost:3000/static/js/bundle.js:199272:58)
at http://localhost:3000/static/js/bundle.js:199291:7
Expected Behavior
不显示该报错
Steps To Reproduce
运行官网演示代码
ReproducibleCode
No response
Environment
Anything else?
[eslint]
src\Chat.js
Line 2:16: 'Radio' is defined but never used no-unused-vars
Line 75:28: React Hook useCallback does nothing when called with only one argument. Did you forget to pass an array of dependencies? react-hooks/exhaustive-deps
Search for the keywords to learn more about each warning.
To ignore, add // eslint-disable-next-line to the line before.
WARNING in [eslint]
src\Chat.js
Line 2:16: 'Radio' is defined but never used no-unused-vars
Line 75:28: React Hook useCallback does nothing when called with only one argument. Did you forget to pass an array of dependencies? react-hooks/exhaustive-deps
webpack compiled with 1 warning
The text was updated successfully, but these errors were encountered: