The problem that vue dynamic paths and multiple routes share the same component

ask a question from vue. I now have a scenario where multiple sidebar navigation routes point to the same page (note that sidebar navigation will be explained later). All that has changed is the data in the List list. The route now says "die". How to die? For example, the navigation paths / path1 and / path2 point to both someComponent components. So now I just want to use the dynamic path /: somePath to point to the same component, and then write logic in this someCompoent component to match this.$route.params .

but one of the problems I encounter now is: after the successful login of the page, I first traverse my routing configuration object, and then generate a sidebar to navigate and render to the page, which leads me to write a dynamic path. Traversing the rendering sidebar navigation will cause a problem. How to solve it?


ide/essentials/redirect-and-alias.html-sharp%E9%87%8D%E5%AE%9A%E5%90%91" rel=" nofollow noreferrer "> https://router.vuejs.org/zh/g.


mine is also written dead
onRoutes ='/ forgetpass'?'/ setting': onRoutes"
I am a set route. The home page that needs to be set up also needs to set up the password change page. My method is stupid. I did this

.
Menu