美文网首页
vue2-swiper

vue2-swiper

作者: 我是苏大大 | 来源:发表于2017-02-25 11:10 被阅读0次

import Swiper from './../static/swiper-3.4.0.min.js'

require('./../static/swiper-3.4.0.min.css')

export default {

mounted () {

var swiper = new Swiper('.swiper-container', {

pagination: '.swiper-pagination',

nextButton: '.swiper-button-next',

prevButton: '.swiper-button-prev',

slidesPerView: 1,

paginationClickable: true,

spaceBetween: 30,

loop: true

});

console.log(swiper)

}

}

html {

height: 100%;

}

body {

display: flex;

align-items: center;

justify-content: center;

height: 100%;

}

#app {

color: #2c3e50;

margin-top: -100px;

max-width: 600px;

font-family: Source Sans Pro, Helvetica, sans-serif;

text-align: center;

}

#app a {

color: #42b983;

text-decoration: none;

}

.logo {

width: 100px;

height: 100px

}

.swiper-container{

width: 500px;

height: 360px;

}

相关文章

  • vue2-swiper

    import Swiper from './../static/swiper-3.4.0.min.js' requ...

网友评论

      本文标题:vue2-swiper

      本文链接:https://www.haomeiwen.com/subject/ppigwttx.html