This commit is contained in:
唐明明
2022-06-07 16:37:03 +08:00
parent b1e8d774ff
commit 1c6091371e
1706 changed files with 225309 additions and 1 deletions

35
router/index.js Normal file
View File

@@ -0,0 +1,35 @@
import {
RouterMount,
createRouter
} from 'uni-simple-router';
import store from '@/store/index'
// CALL 页面必须是nvue但是NVUE 不支持webpack的 ROUTES 注入
// https://github.com/SilurianYang/uni-read-pages/issues/20
// #ifdef APP-NVUE
const ROUTES = [{
"path": "/pages/im/private/call"
}];
// #endif
const router = createRouter({
platform: process.env.VUE_APP_PLATFORM,
routes: [...ROUTES]
});
// console.log(...ROUTES)
//全局路由前置守卫
router.beforeEach((to, from, next) => {
next();
});
// 全局路由后置守卫
router.afterEach((to, from) => {
// console.log('跳转结束')
})
export {
router,
RouterMount
}