All Projects → fffixed → vue-bus

fffixed / vue-bus

Licence: MIT license
Tiny simple central event bus plugin for Vue.js

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to vue-bus

Vue Tabevents
Event-Based communication across opened tabs for Vue 2.x
Stars: ✭ 31 (-38%)
Mutual labels:  events, vue-plugin
GETProtocolCore
🎫 Contract overview and definition of GET Protocol's NFTs
Stars: ✭ 31 (-38%)
Mutual labels:  events
SwiftHooks
Event driven programming in Swift
Stars: ✭ 17 (-66%)
Mutual labels:  events
vip-git
💊 Automated "hey" · ·👋 · · of the day. Every day a unique historic event is generated based on the given day.
Stars: ✭ 4 (-92%)
Mutual labels:  events
go-graphql-subscription-example
☝️ go-graphql subscription over Kafka/Redis/NSQ example
Stars: ✭ 34 (-32%)
Mutual labels:  events
pholiday
a persian calendar holidays library for javascript
Stars: ✭ 38 (-24%)
Mutual labels:  events
ng2-events
Supercharge your Angular2+ event handling
Stars: ✭ 17 (-66%)
Mutual labels:  events
generator-vue-plugin
Yeoman generator generating vue plugin 🚀
Stars: ✭ 29 (-42%)
Mutual labels:  vue-plugin
ikisocket
🧬 WebSocket wrapper with event management for Fiber https://github.com/gofiber/fiber. Based on Fiber WebSocket and inspired by Socket.io
Stars: ✭ 92 (+84%)
Mutual labels:  events
vue-ray
Debug your Vue 2 & 3 code with Ray to fix problems faster
Stars: ✭ 48 (-4%)
Mutual labels:  vue-plugin
Timespace
A jQuery plugin to handle displaying of time events
Stars: ✭ 27 (-46%)
Mutual labels:  events
tardis
Event sourcing toolkit
Stars: ✭ 35 (-30%)
Mutual labels:  events
yii-event
Events for Yii applications
Stars: ✭ 12 (-76%)
Mutual labels:  events
2020.djangocon.eu
🚃 The DjangoCon EU 2020 conference website
Stars: ✭ 16 (-68%)
Mutual labels:  events
search-insights.js
Library for reporting click, conversion and view metrics using the Algolia Insights API
Stars: ✭ 39 (-22%)
Mutual labels:  events
EasyEventEditor
Drop in replacement for the default Unity event editor drawer that allows listener reordering
Stars: ✭ 103 (+106%)
Mutual labels:  events
vue-svg-inline-plugin
Vue plugin for inline replacement of SVG images with actual content of SVG files.
Stars: ✭ 30 (-40%)
Mutual labels:  vue-plugin
trainmanjs
TrainmanJS - Cross-Origin Communication Library
Stars: ✭ 16 (-68%)
Mutual labels:  events
vector
A high-performance observability data pipeline.
Stars: ✭ 12,138 (+24176%)
Mutual labels:  events
consolidated-events
Manage multiple event handlers using few event listeners
Stars: ✭ 44 (-12%)
Mutual labels:  events

vue-bus

awesome-vue license

A tiny simple central event bus plugin for Vue.js (requires Vue >= 2.0).

The plugin realise Non Parent-Child Communication.

(655 byte gzip)

Installation

Download and use with your build system

import VueBus from 'vue-bus'
// ... maybe ...
var VueBus = require('vue-bus')

// ...  and  ...

Vue.use(VueBus)

Or just include it with a script tag

<script src="/vue-bus.js"></script>

Usage

direct way:

// in component A's method
this.$bus.$emit('my-event', 1)

// in component B's created hook
this.$bus.$on('my-event', function(arg) {
  // ...
})

//And don't forget to use "this.$bus.$off" to remove unnecessary listeners.

magic way:

// in component A's method
this.$bus=['my-event', 1]

// in component B create $bus option
methods: { /* ... */ },
$bus: {
  'my-event': function(arg) {
    // ...
  }
}

License

MIT

Copyright (c) 2017 fffixed

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].