feat: 双token

This commit is contained in:
2026-06-16 18:19:48 +08:00
parent 172c83ea73
commit cb9687e472
8 changed files with 221 additions and 119 deletions

View File

@@ -23,7 +23,7 @@ function setupCommonGuard(router: Router) {
const accountStore = useAccountStore()
// 首次导航时验证 token 有效性(检查持久化的 token 是否过期)
await accountStore.initAuth()
// await accountStore.initAuth()
// 已登录用户访问公开路由(如登录页),直接跳转首页
if (accountStore.isLoggedIn() && isPublicPath(to.path)) {