fix: one page swiper broken

This commit is contained in:
Raistlin916 2017-08-07 20:07:33 +08:00
parent 5e02c59736
commit 66c3b2c6eb

View File

@ -36,6 +36,11 @@ export default {
},
mounted() {
const pages = this.$el.querySelectorAll('.van-swipe-item')
if (pages.length <= 1) {
return
}
this.input = new Input(this.$el, {
listenMoving: true
});