Vue routing Jump problem

if the current page is under / , use < router-link: to= "{path:"/",query: {category_id:item.id}}" > jump < / router-link > to jump. In fact, the page has no jump effect, can it be processed as similar to the jump effect between different routes?

as shown in figure

Article is under / , and under Category is under /? category_id=n . I hope you can jump by clicking instead of just adding parameters

.
Feb.27,2021

can you state your purpose of doing this?

  • has encountered a similar problem. Skipping the current page on the current page will flash the value found by the last id. I don't know what problem you are trying to solve

does not understand your question. If you want to jump to the specified route when the page is / , you can use redirection. See

routes: [
        { path: '/', redirect: to => {
            //   
            // return  /
        }}
    ]

and < router-link > acts like the a tag, which needs to be triggered by you to execute

.
<div @click="jump"></div>

jump(){
    this.$router.push({
        path: '/home'
      })
}

only if home is configured for routing, such as redirection

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-1beb8fb-31a6f.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-1beb8fb-31a6f.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?