@hokid/webapp-service-vuefycations
v0.0.1
Published
catch events and trigger notifications. it use vue, buefy and eventemitter
Downloads
2
Readme
Usage
import Vue from 'vue';
import Vufycations from '@hokid/webapp-service-vuefycations';
import EE from 'events';
Vue.use(Vufycations, {
EventEmitter: EE,
default: {
duration: 4000,
position: 'is-bottom-right',
type: 'is-info'
},
events: [
{
name: 'event-a',
toast: {
message: 'Event A happens',
type: 'is-info'
}
},
{
name: 'event-b',
toast(event) {
const message = event.message;
return {
message: 'Event B happens, message: ' + message,
type: 'is-info'
};
}
}
]
});