vue-slide2
v1.0.0
Published
A slide component for Vue
Downloads
12
Readme
vue-slide
A slide component for Vue. :boom: :boom: :boom: :boom:
Installing
$ npm install vue-slide2 --saveExample
<template>
<slide :imgs="imgs" :currentIndex="index" v-if="slideStatus" @hiddenSlide="hiddenSlide"></slide>
</template>
<script>
import slide from "vue-slide2"
export default {
data() {
imgs: [],
index: 0,
slideStatus: false
},
methods: {
hiddenSlide() {
this.slideStatus = false
}
}
}
</script>Options
Props
Props | Type | Default | Description ------------ | ------------- | ------------- | ------------- imgs | Array | null | The image of the slide. currentIndex | Number | 0 | The index of the slide.
Events
Name | Description ------------ | ------------- hiddenSlide | Hide the slide.
