mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2025-11-15 14:03:36 +08:00
perf: 页面切换性能优化 (#600)
* perf: 页面切换性能优化 * fix: 修复刷新页面时`router.beforeEach`调用两次的问题
This commit is contained in:
@@ -1,21 +1,13 @@
|
||||
import type { Emitter } from "mitt";
|
||||
import mitt from "mitt";
|
||||
|
||||
/** 全局公共事件需要在此处添加类型 */
|
||||
type Events = {
|
||||
resize: {
|
||||
detail: {
|
||||
width: number;
|
||||
height: number;
|
||||
};
|
||||
};
|
||||
openPanel: string;
|
||||
tagViewsChange: string;
|
||||
tagViewsShowModel: string;
|
||||
logoChange: boolean;
|
||||
changLayoutRoute: {
|
||||
indexPath: string;
|
||||
parentPath: string;
|
||||
};
|
||||
changLayoutRoute: string;
|
||||
};
|
||||
|
||||
export const emitter: Emitter<Events> = mitt<Events>();
|
||||
|
||||
Reference in New Issue
Block a user