How does vue set up a page refresh before entering a route?

I used to make a route judgment in the navigation guard in the component. If it was a route before, I refreshed the page once, but now the requirement is not to judge, no matter which page is refreshed before entering the login page. I have tried a lot of methods to refresh the page indefinitely.

beforeRouteEnter(to,from,next){
    //
    if(from.name == "dealCenter"){
        window.location.reload()
    }
    next()
}
Feb.21,2022

resolved

//main.js
router.beforeEach((to,from,next) => 
        var reloaded = window.localStorage.getItem('reloaded') || '';
        if(reloaded == ''&&to.name == 'login'){
            window.location.reload();
            window.localStorage.setItem('reloaded','yes');
        }
        next()        
    })
})
//login.vue
beforeDestroy(){
    window.localStorage.removeItem('reloaded');
}
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b37980-2aded.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b37980-2aded.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?