vue-input-tag
Advanced tools
Comparing version
{ | ||
"name": "vue-input-tag", | ||
"version": "0.0.4", | ||
"version": "0.0.5", | ||
"description": "Vue.js input tag editor component", | ||
@@ -5,0 +5,0 @@ "author": "Matias Tucci <matiastucci@gmail.com>", |
# vue-input-tag | ||
> A Vue.js project | ||
> A Vue.js 2.0 input tag component inspired in [react-tagsinput](https://github.com/olahol/react-tagsinput) | ||
## Build Setup | ||
## Installation | ||
``` bash | ||
# install dependencies | ||
npm install | ||
npm install vue-input-tag --save | ||
``` | ||
# serve with hot reload at localhost:8080 | ||
npm run dev | ||
and in your component: | ||
# build for production with minification | ||
npm run build | ||
``` javascript | ||
import InputTag from 'vue-input-tag' | ||
``` | ||
# run unit tests | ||
npm run unit | ||
## Usage | ||
# run all tests | ||
npm test | ||
``` html | ||
<input-tag :on-change="callbackMethod" :tags="tagsArray"></input-tag> | ||
``` | ||
For detailed explanation on how things work, checkout the [guide](http://vuejs-templates.github.io/webpack/) and [docs for vue-loader](http://vuejs.github.io/vue-loader). | ||
## Props | ||
| Name | Type | Default | Description | | ||
| ---:| --- | ---| --- | | ||
| tags | Array | [] | Tags to be render in the input | | ||
| placeholder | String | "" | Placeholder to be shown when no tags | | ||
| read-only | Boolean | false | Set input to readonly | | ||
| on-change | Function | undefined | Callback to get the tags when there is a change | |
47374
0.57%32
28%