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
UncontrolledTooltip should not raise an error when the target ID does not exist in the DOM #1593
Comments
Having the same issues with Uncontrolled Tooltips and Badges. |
+1 Also: #773, so sometimes it will crash even if the id is spelled correctly. I think this should be |
Is there any progress on this? |
Not sure why it this ticket hasnt been updated, but I've encountered the same issue using version |
This issue is still present, even if in v8.8.1 a "safe-render" was added the problem is Lines 297 to 301 in 551d9ee
This issue is caused when tooltip and target are created togheter, thus the target does not yet exists in the DOM while the tooltip is moutend. This happens only if the tooltip is open at first render ( |
Definitely not fixed, we see frequent crashes in Sentry due to this. |
Issue description
^8.0.0
^16.8.6
What is happening?
UncontrolledTooltip (and maybe other Uncontrolled components?) raise an error in the React application when the target ID does not exist in the DOM.
What should be happening?
Instead of raising an error which can make the whole React application crash (imho this does not seem to be a critical problem, but more of an UX one), maybe it should just warn the developer/user through the console and peacefully not show the tooltip.
Steps to reproduce issue
Error message in console
No error in console.
The text was updated successfully, but these errors were encountered: