Akryum / floating-vue

💬 Easy tooltips, popovers, dropdown, menus... for Vue
https://floating-vue.starpad.dev/
MIT License
3.32k stars 339 forks source link

TypeError addResizeHandlers #911

Open tomosterlund opened 1 year ago

tomosterlund commented 1 year ago

First of all, thanks for your work on this library.

In a production app, we have an error which keeps coming back a few times a month.

Error type is always as in the issue title TypeError addResizeHandlers.

Message is always the following: null is not an object (evaluating 'this._resizeObject.contentDocument.defaultView') and it seems to be appearing only on Safari desktop and mobile, versions 14.1 through 16. The stacktrace leads us to our vendor javascript file, and more specifically to our installation of floating-vue. The last action that Sentry records for us in relation to the error, is always a click on some element, which is totally unrelated to our implementations of the library.

One suspicion I have, is that we're force displaying an element with this library somewhere else in the application, and that the element is no longer available when floating-vue is still executing. Maybe just a null-check is missing somewhere?