react-tippy
react-tippy copied to clipboard
Cannot read property 'settings' of undefined
HI there,
Great lib, very handy and simple. I'm getting below error when I have hundreds of <div>'s rendered. That seems to be related to the mounting/unmounting mechanism in React-Tippy.
The data property within R-T is undefined.
Any chance to help me debugging this?
Thanks J.
react-tippy.js:2317 Uncaught TypeError: Cannot read property 'settings' of undefined
at Tippy.hide (react-tippy.js:2317)
at hide (react-tippy.js:1561)
at triggerHide (react-tippy.js:1596)
at HTMLDocument.handleMousemove (react-tippy.js:1613)
When I removed "delay" property from settings tippy component it became works fine for me
You mean setting "delay" to 0? That is its default value.
Or you mean some other hack? Can you detail a bit?
Thanks and happy Christmas!
In my project I used delay=300, and I reproduced the same bug. But when I had removed this delay setting this bug disappeared and it worked fine. Happy Christmas to you too!
To solve this problem you can simply replace 'title' attribute with HTML content like this
<Tooltip
trigger="mouseenter"
size='small'
html={(
<p>here's your tooltip also you can get info like this</p>
)}>
Hover me, this will fix your problem
</Tooltip>
Hi @liamm12 I'm already using html and it's not working for me. It sounds like the React Component unmounts before tippy hides, then when tippy tries to hide it crashes.
Any other idea on how to fix this?
Having the same issue by just updating the disabled props to true.

This is causing us unrecoverable crashes in production. Anyone working on a fix?
I have similar issues:
Cannot read property 'el' of undefined
if (!document.body.contains(data.el)) {
this.destroy(popper);
return;
}
I also get Cannot read property 'settings' of undefined
Sorry for not being active on Github, @bernatfortet can you attach your code on CodeSandBox so we could identify the source of this problem
@jabidof did you find a way to fix this? I've been gnashing teeth on it.
@farukg any luck on this?
@sontek Any workaround or fixes you figured out?
Still a problem. Gosh!! Is there a way to block tippy on touch devices?
For me it was if I was using the delay it will give this error. Now, after removing, it works, (i think so)
Ran into this issue when putting a button inside the tooltip. Removing the 'onClick' handler worked, but unfortunately I kinda need it. Edit: the onClick handler was eventually affecting state that caused the tooltip to get re-rendered. Gonna try fiddling with a delay, or maybe a manual hide after changing state.
The same issue, but it only occurs on IE 11 or edge.