JS订阅者模式的使用(在微信小程序中的使用)
var listenerObj //订阅者模式 function publicListener() { this.handlers = {} } publicListener.prototype = { on: function (eventType, handler) { var self = this; if (!(eventType
var listenerObj //订阅者模式 function publicListener() { this.handlers = {} } publicListener.prototype = { on: function (eventType, handler) { var self = this; if (!(eventType