ant-design-vue/components/vc-slick/demo/CustomSlides.jsx

41 lines
751 B
Vue
Raw Normal View History

2018-07-20 08:13:21 +00:00
import '../assets/index.less'
import Slider from '../src/slider'
const CustomSlide = {
props: ['index'],
render () {
return (
<div>
<h3>{this.index}</h3>
</div>
)
},
}
export default {
render () {
const settings = {
props: {
dots: true,
infinite: true,
speed: 500,
slidesToShow: 1,
slidesToScroll: 1,
},
}
return (
<div>
<h2>Custom Slides</h2>
<Slider {...settings}>
<CustomSlide index={1} />
<CustomSlide index={2} />
<CustomSlide index={3} />
<CustomSlide index={4} />
<CustomSlide index={5} />
<CustomSlide index={6} />
</Slider>
</div>
)
},
}