New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

vue-tribute

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vue-tribute

A Vue.js wrapper for Zurb's Tribute library for native @mentions

  • 1.0.7
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
741
decreased by-78.18%
Maintainers
1
Weekly downloads
 
Created
Source

vue-tribute

Build Status

A Vue.js wrapper for Zurb's Tribute library for native @mentions.

Install

$ yarn add vue-tribute

or

$ npm install vue-tribute --save

or include the UMD build, hosted by unpkg in a <script> tag.

<script src="//unpkg.com/vue-tribute" />

Usage

Import and register the component.

import VueTribute from 'vue-tribute'

export default {
  ...
  components: {
    VueTribute
  }
}

In your template, wrap an input, textarea or contenteditable element in the vue-tribute component, and pass your Tribute options in.

<div>
  <vue-tribute :options="tributeOptions">
    <input type="text" placeholder="@..." />
  </vue-tribute>
</div>

See the available Tribute options here.

Events

Tribute broadcasts two events — a tribute-replaced event, and a tribute-no-match event (see docs here). Listeners for these events can be attached directly to the child element of the <vue-tribute> component. Eg:

<vue-tribute :options="options">
  <input type="text" placeholder="@..." @tribute-no-match="noMatchFound" />
</vue-tribute>

Development

# To run the example
$ npm run example

# To run the tests
$ npm test

# To publish the dist file
$ npm run build

License

MIT © Collin Henderson

FAQs

Package last updated on 11 Apr 2021

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc