Publishing TagInput component to npm

#8 Wrapping TagInput component using the template from last tip

This is the repository and this is the code that matters

https://github.com/vuejs-tips/v-tag-input/blob/master/src/Component.vue

Lines 21 and 24 are where the magic happens. The input array is converted to string and bound to the input, and the input string is converted back to array before $emit it.

Demo 1

Demo 2

You can link in you own project using one of those urls:

  1. https://rawgit.com/vuejs-tips/v-tag-input/master/dist/v-tag-input.js
  2. https://unpkg.com/v-tag-input
  3. Or yarn add v-tag-input

The final component has only 1KB (gziped). Pretty lite for a tag input, hum?

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.