与原生scrollTo冲突?
Wwwhisperr opened this issue · comments
Version
2.4.2
Reproduction link
https://github.com/Wwwhisperr/supermall.git
Steps to reproduce
1、npm install下载包后npm run serve运行项目,滑动一下后按右下角的“回到顶部按钮”,位于src/views/home/Home.vue组件里medthods里better-scroll的this.$refs.scroll.scroll.scrollTo(0,0,500)不生效。
2、this.$refs.scroll返回的是封装了better-scroll的组件,this.$refs.scroll.scroll是存了better-scroll对象的一个变量。
3、但是在better-scroll方法里直接用scrollTo(0,0,500)是生效的
What is expected?
成功调用better-scroll的scrollTo方法
What is actually happening?
没有成功调用better-scroll的scrollTo方法