2025-05-14 20:54:01 +08:00
|
|
|
import { createRouter, createWebHashHistory, Router } from 'vue-router';
|
|
|
|
import {getAccessTime} from '@/api/index';
|
2025-03-19 13:15:34 +08:00
|
|
|
import routes from './routes';
|
2025-05-14 20:54:01 +08:00
|
|
|
import {showDialog } from 'Vant';
|
2025-03-19 13:15:34 +08:00
|
|
|
|
|
|
|
const router: Router = createRouter({
|
2025-05-14 20:54:01 +08:00
|
|
|
history: createWebHashHistory(import.meta.env.BASE_URL),
|
2025-03-19 13:15:34 +08:00
|
|
|
routes: routes,
|
|
|
|
});
|
|
|
|
|
2025-05-17 10:13:32 +08:00
|
|
|
router.beforeEach(async (_to, _from, next) => {
|
|
|
|
next();
|
2025-03-19 13:15:34 +08:00
|
|
|
});
|
|
|
|
|
2025-05-17 10:13:32 +08:00
|
|
|
|
2025-03-19 13:15:34 +08:00
|
|
|
export default router;
|