Don't attach tooltips to document.body | Atif Afzal
Don’t attach tooltips to document.body TL;DR Instead of attaching tooltips directly to document.body, attach them to a predefined div in document.body. BAD %3Cbody%3E -- temporary div, vanishes when tooltips vanishes --> %3Cdiv%3Emy tooltip%3C/div%3E %3Cbody%3E GOOD %3Cbody%3E -- this div stays forever, just for attaching tooltips --> %3Cdiv%20id=%22tooltips-container%22%3E -- temporary div, vanishes when tooltips vanishes --> %3Cdiv%3Emy tooltip%3C/div%3E %3C/div%3E %3Cbody%3E Introduction Tooltips in our app were taking >80ms. And during this time, the main thread was blocked, you couldn’t interact with anything.