Skip to content

Commit ef91b40

Browse files
committed
fix(slide): update currentIndex in scrollEnd handler
#278
1 parent 8da8caa commit ef91b40

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/components/slide/slide.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,9 +206,10 @@
206206
207207
this.slide = new BScroll(this.$refs.slide, options)
208208
209+
this.slide.on('scrollEnd', this._onScrollEnd)
210+
209211
this.slide.goToPage(this.currentPageIndex, 0, 0)
210212
211-
this.slide.on('scrollEnd', this._onScrollEnd)
212213
/* dispatch scroll position constantly */
213214
if (this.options.listenScroll && this.options.probeType === 3) {
214215
this.slide.on('scroll', this._onScroll)

0 commit comments

Comments
 (0)