-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
useWebSocket初始socketUrl为空报错,更新socketUrl导致无限重连 #2176
Comments
YinDongFang
added a commit
to YinDongFang/hooks
that referenced
this issue
Apr 26, 2023
YinDongFang
added a commit
to YinDongFang/hooks
that referenced
this issue
Apr 26, 2023
YinDongFang
added a commit
to YinDongFang/hooks
that referenced
this issue
Apr 26, 2023
相关issue:#1523 |
crazylxr
pushed a commit
that referenced
this issue
Jun 6, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
问题1:
useWebSocket
参数socketUrl
初始值为空报错复现地址:https://codesandbox.io/s/empty-initial-socketurl-z2uwvm?file=/App.tsx
预期:当初始
socketUrl
为空值时不执行connect
问题2:
useWebSocket
更新socketUrl
导致无限重连复现地址:https://codesandbox.io/s/update-socketurl-d1jjww?file=/App.tsx
复现步骤:等待连接成功后点击
update
预期:更新socketUrl后重新建立连接并不会触发reconnect
The text was updated successfully, but these errors were encountered: