Merge branch 'dev' into master-fetch-dev

This commit is contained in:
奔跑的面条
2023-02-09 16:24:19 +08:00
8 changed files with 44 additions and 16 deletions
+1
View File
@@ -2,3 +2,4 @@ export { setupNaive } from '@/plugins/naive'
export { setupDirectives } from '@/plugins/directives'
export { setupCustomComponents } from '@/plugins/customComponents'
export { icon } from '@/plugins/icon'
export { initFunction } from '@/plugins/initFunction'
+9
View File
@@ -0,0 +1,9 @@
/**
* * 页面初始化就执行的函数
*/
export const initFunction = async () => {
// 捕获全局错误
window.addEventListener("unhandledrejection", event => {
console.warn(`UNHANDLED PROMISE REJECTION: ${event.reason}`);
});
}