let groups =document.getElementById('groupstop') console.log('距离顶部距离',groups.offsetTop -document.documentElement.scrollTop)
let groups =document.getElementById('groupstop')
console.log('距离顶部距离',groups.offsetTop -document.documentElement.scrollTop)
本文标题:元素距离顶部距离
本文链接:https://www.haomeiwen.com/subject/crujgktx.html
网友评论