scroll-view无法获取ref 你不会困 2023-05-21 652 阅读1分钟 scroll-view无法获取ref,想点击回到顶部时,无法通过this.$refs这种方式回到顶部 this.$refs.scrollView.scrollTo({ top: 0, duration: 300 }); 查看官方文档的解决方案,动态传入 :scroll-top="scrollTop"