Created
January 2, 2019 09:14
-
-
Save monsterooo/9752eb2b607e8033f3fb1461264b7696 to your computer and use it in GitHub Desktop.
获取浏览器滚动元素
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getBodyScrollTop () { const el = document.scrollingElement || document.documentElement return el.scrollTop } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment