1.0.4 • Published 7 years ago
vue-page-swipe v1.0.4
vue-page-swipe
a page swipe using vue.js (using slot and render)
Using vue-page-swipe
Install
$ npm install vue-page-swipe
Import and register module
import PageSwipe from 'vue-page-swipe';
Vue.component('page-swipe', PageSwipe);
Using "page-swipe" tag simply
<page-swipe>
<div swipe-title="page1" class="page1">Page1</div>
<div swipe-title="page2" class="page2">Page2</div>
<div swipe-title="page3" class="page3">Page3</div>
</page-swipe>
Develop
Run example:
$ npm run dev
Build src to /dist
$ npm run build
Options
For page-swipe
Option | Description |
---|---|
showIndicators | Boolean (default: true) - Defines whether indicators are shown or not. |
allowLoop | Boolean (default: false) - If set to true, scrolling up in the first page will scroll to the last page, and scrolling down in the last page will scroll to the first page. |
direction | String (default: vertical) - Defines the scroll direction is vertical or horizontal |
For children under page-swipe
Option | Description |
---|---|
swipe-title | String - Defines the text shown beside indicators while hovering on indicators. |