Javascript: does scrollTop / scrollLeft change the trigger browser?

I am wondering if the animation is scrollbars using Javascript triggers for the browser.

Any difference in different browser implementations?

window.pageXOffset and window.pageYOffset
document.documentElement.scrollLeft and document.documentElement.scrollTop
document.body.scrollLeft and document.body.scrollTop

Thank!

+5
source share
2 answers

I went deeper and found this link, which says that it causes reflection: http://www.phpied.com/rendering-repaint-reflowrelayout-restyle/

scrollTop scrollLeft reflow ( , Firefox).

, , , , -:).

+9

, .

0

All Articles