Socket
Socket
Sign inDemoInstall

vuetagger

Package Overview
Dependencies
0
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    vuetagger

Simple Vue.js tag component


Version published
Maintainers
1
Install size
5.57 kB
Created

Readme

Source

Vuetagger

Simple tag component for Vue.js 1.* and 2.0

Usage

The <template>

<vuetagger :value="tags" @change="updateTags"></vuetagger>

On your <script>

export default {

  components: {
    vuetagger: require('./Vuetagger')
  },

  data() {
    return {
      tags: []
    }
  },

  methods: {
    updateTags(tags) {
      console.log(tags)
    }
  }

}

Regex Pattern (optional)

You could add a regex pattern to the attribute. If the regex pattern does not match, the new tag wouldn't be added.

Here is the example with regex pattern I've taken from http://emailregex.com/

<vuetagger
  :value="tags"
  @change="updateTags"
  pattern="^[-a-z0-9~!$%^&*_=+}{\'?]+(\.[-a-z0-9~!$%^&*_=+}{\'?]+)*@([a-z0-9_][-a-z0-9_]*(\.[-a-z0-9_]+)*\.(aero|arpa|biz|com|coop|edu|gov|info|int|mil|museum|name|net|org|pro|travel|mobi|[a-z][a-z])|([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}))(:[0-9]{1,5})?$"
></vuetagger>

License

MIT @ Mulia Arifandi Nasution

Keywords

FAQs

Last updated on 21 Oct 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc