Skip to content

ygtzz/vue-slide-nav

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

vue-slide-nav

Install

npm install vue-slide-nav -S

yarn add vue-slide-nav

QuickStart

require('vue-slide-nav/dist/vue-slide-nav.css');

// in ES6 modules
import { slideNav } from 'vue-slide-nav';

// in CommonJS
const { slideNav } = require('vue-slide-nav');

// in Global variable
const { slideNav } = VueSlideNav;

Vue.component('c-slide-nav',slideNav);
<!-- in vue template -->
<!--list:[
    {text:'bing'},
    {text:'sougou搜索'},
    {text:'360',callback:funcion(){}},
    {text:'百度一下'}
]-->
<c-slide-nav :items="list" back-class="backLine"></c-slide-nav>

Params

  • items: a list contains {text:'',link:''} object,text respents item's text,if callback,it will be call after click
  • offset: the back item's left and right padding to normal item
  • backClass: the back item's class, defalut is backBar, other build-in class is backLine

Preview

slide nav image

About

a vue slide nav component

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published