router.beforeEach((to, from, next) => { //拦截指定路由 if(to.path === ‘/home‘){ //todo }else{ scrollTo(0, 0); next(); } })
原文地址:https://www.cnblogs.com/223zzm/p/11747116.html
时间: 2024-10-25 11:36:07
router.beforeEach((to, from, next) => { //拦截指定路由 if(to.path === ‘/home‘){ //todo }else{ scrollTo(0, 0); next(); } })
原文地址:https://www.cnblogs.com/223zzm/p/11747116.html