What exactly does ReactTooltip rebuild do, and when is it required?
See original GitHub issueThanks for this awesome library. I had a question about the static rebuild method.
I have been using ReactTooltip in my application and it works in certain places. The places that it doesn’t work in requires a rebuild (like below) to make it work.
componentDidUpdate() {
ReactTooltip.rebuild();
}
When exactly is it necessary to do a rebuild? And what is it doing? Thanks!
Issue Analytics
- State:
- Created 6 years ago
- Reactions:21
- Comments:7
Top Results From Across the Web
What exactly does ReactTooltip rebuild do, and when is it ...
I have been using ReactTooltip in my application and it works in certain places. The places that it doesn't work in requires a...
Read more >What exactly does ReactTooltip rebuild do, and when is it required?
I have been using ReactTooltip in my application and it works in certain places. The places that it doesn't work in requires a...
Read more >React-tooltip doesn't show on conditional render
You need to rebuild your tooltips with ReactTooltip.rebuild post a render and ... components with hooks, you can do so with useEffect hooks...
Read more >Top 5 react-tooltip Code Examples - Snyk
Learn more about how to use react-tooltip, based on react-tooltip code examples ... Use Snyk Code to scan source code in minutes -...
Read more >Build a React tooltip from scratch - YouTube
Copy link. Info. Shopping. Tap to unmute. If playback doesn't begin shortly, try restarting your device. Your browser can 't play this video....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I was thinking, why is React Tooltip designed in a way that needs rebuilding? Why doesn’t it use mouse over event on the container to find pointed element’s potential tooltips? The way it works now, with the rebuild, feels very jQuery-esque.
@CWSites I just ran into this and it appears to be related to components with the
data-for
props loading later than the ReactTooltip component.E.g. I had a dynamically loading infinite scrolling feed, and the first ‘page’ loaded the tooltip correctly for all its subcomponents. I use one tooltip to cover all those elements, which worked fine for the entries that were loaded before the tooltip was. However, if I loaded more content afterwards, the tooltip would not show for newer content. Calling rebuild() after loading new content fixed that, as it rebinds the newly loaded
data-for
-containing components to the tooltip.