var swiper = new Swiper('.swiper-container', { initialSlide: 1, // 設(shè)置初始化后的默認(rèn)第一張圖 pagination: '.swiper-pagination', effect: 'coverflow', grabCursor: true, centeredSlides: true, slidesPerView: 'auto', coverflow: { rotate: 50, stretch: 0, depth: 100, modifier: 1, slideShadows: true }, onSlideChangeEnd: function (swiper) { alert(swiper.activeIndex) //切換結(jié)束時(shí),告訴我現(xiàn)在是第幾個slide }});手速快點(diǎn),滑動了到了另一張圖(已完成加載),alert(swiper.activeIndex) 獲取的還是上一張的索引。請問,每次swiper滑動后,獲取當(dāng)前的這是第幾張圖,但是每次都有延遲,這個問題如何解決
swiper.js 響應(yīng)總是慢一拍
慕田峪7331174
2019-01-30 17:41:59