src/router/index.js @@ -35,6 +35,7 @@ routes, }); router.beforeEach((to, from, next) => { // next(); if (to.path === "/login") { //去登录页,直接跳转 next(); } else { //去index,判断token