UNPKG

olympus-r

Version:

一个力求简单易用的前端开发框架 #### 开发语言 TypeScript #### 核心架构 MVC #### 模块间通讯和解耦 采用事件机制,利用一个全局唯一的事件派发器进行模块间通讯,解耦模块间依赖 #### 表现层结构 使用桥接模式拆分接口与实现,达到一套核心驱动多套表现层的目的(目前支持DOM、Egret、PixiJS三种表现层),同时支持表现层的未来可扩展性 #### TypeScript装饰器注入 框架提供TypeScript装饰器注入功能,便捷获取托管对象。例如:

31 lines (30 loc) 867 B
import * as tslib_1 from "tslib"; import Message from "./Message"; /** * @author Raykid * @email initial_r@qq.com * @create date 2017-09-01 * @modify date 2017-09-01 * * 框架内核通用消息 */ var CommonMessage = /** @class */ (function (_super) { tslib_1.__extends(CommonMessage, _super); /** * Creates an instance of Message. * @param {string} type 消息类型 * @param {...any[]} params 可能的消息参数列表 * @memberof Message */ function CommonMessage(type) { var params = []; for (var _i = 1; _i < arguments.length; _i++) { params[_i - 1] = arguments[_i]; } var _this = _super.call(this, type) || this; _this.params = params; return _this; } return CommonMessage; }(Message)); export default CommonMessage;