javascript - vue2+iscroll5无法滑动
本文介绍了javascript - vue2+iscroll5无法滑动的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
问 题
使用Vue2+iscroll5,初始化可以完成,但是用谷歌浏览器手机模式根本无法滑动,非手机模式下滑动正常。
完全按照官方示例的代码如下:
import IScroll from 'iscroll';
export default {
name: 'app',
data() {
return {
msg: []
}
},
mounted: function() {
this._initScroll();
},
methods: {
_initScroll() {
this.iscroll = new IScroll(this.$refs.wrap);
}
},
components: {}
}
解决方案
推荐使用vue-iscroll-view
这篇关于javascript - vue2+iscroll5无法滑动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文