document.getElementById('你的元素id').scrollIntoView({
behavior: 'smooth',
});
js将指定元素滚动到可见区域内的方法。
最新推荐文章于 2024-06-06 22:56:39 发布
document.getElementById('你的元素id').scrollIntoView({
behavior: 'smooth',
});