If I have lots of DOM on the page and I set them all to display: none, the browser still reacts quickly (scrolling is fast, page feels snappy).
However, if I visibility: hidden the elements, the browser is as slow as if they were all drawn on the screen.
Can someone explain, in detail, why this is the case?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…