智能照明系统APP-本地串口
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
LightingSystemApp-serial/.svn/pristine/6e/6e685098d123e1295a998b41485...

23 lines
437 B

import Vue from 'vue'
const Emitter = new Vue()
function apply (ctx, method, args) {
return ctx[method].apply(ctx, args)
}
export function $on () {
return apply(Emitter, '$on', [...arguments])
}
export function $off () {
return apply(Emitter, '$off', [...arguments])
}
export function $once () {
return apply(Emitter, '$once', [...arguments])
}
export function $emit () {
return apply(Emitter, '$emit', [...arguments])
}