var swiper = new Swiper('.banner', {
spaceBetween:0,
centeredSlides: true,
autoplay: {
delay: 5000,
disableOnInteraction: false,
},
pagination: {
el: '.swiper-pagination',
clickable: true,
},
loop: true,
navigation: {
nextEl: '.swiper-button-next',
prevEl: '.swiper-button-prev',
},
speed:1300
});
1. speed---控制切换速度
2.spaceBetween---控制两个splide的间距
3. loop---循环滚动
4.pagination---下面小点
5.navigation---左右切换箭头
6.autoplay---自动切换配置