-
Notifications
You must be signed in to change notification settings - Fork 321
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
fix: remove return null check from OverlayProvider and Chat component #2039
Conversation
Also, I think it is a good idea to remove some parts from useEffect so that it happens during render and not after the render maybe using usememo or bringing the translators state inside.. this whole hook seems badly done in the first place in my view 😢 I am talking about the following parts
There is no reason to run the promise after the render actually if you think about it.. What say? |
I have moved the translator state inside, because it makes sense to me. |
Kudos, SonarCloud Quality Gate passed! |
@@ -226,8 +217,6 @@ const ChatWithContext = < | |||
enableOfflineSupport, | |||
}); | |||
|
|||
if (loadingTranslators) return null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make sure to test it by adding some delays to streami18n.getTranslators()
method. Just to check whats the behavior when translators
is not ready
🎉 This PR is included in version 5.14.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
🎯 Goal
Fixes #2037
🛠 Implementation details
🎨 UI Changes
iOS
Android
🧪 Testing
☑️ Checklist
develop
branch