if(to.matched.some(record =>to.meta.requiresAuth)){ if(store.getters.isAuthenticated == true) next() else next({name: "Login"}) } e