wtbf-vue-dropdown
v0.0.6
Published
vue dropdown component.
Downloads
6
Readme
vue-dropdown
This is yet another vue dropdown component.
Install
Use npm to download code:
npm install wtbf-vue-dropdown -S
then import it into your project, add below code into your main.js
:
import Dropdown from 'wtbf-vue-dropdown'
Vue.use(Dropdown)
Usage
<template>
<dropdown :data="data" :cbChanged="changed"></dropdown>
</template>
<script>
const data = [{
label: 'Volvo',
value: 1
}, {
label: 'Saab',
value: 2
}, {
label: 'Long long long long long long test',
value: 2
}]
export default {
data() {
return {
data
}
},
methods: {
changed(selected) {
console.log(selected)
}
}
}
</script>
Props
Coming...
Demo
Screenshot
source
https://www.npmjs.com/package/hsy-vue-dropdown