Skip to content

Different route define, but the same suffix path, will all be actived! #1091

Closed
@muei

Description

@muei

vue-router's version: 3.10.9

// routes.js
const routes = [
   {name: 'tag', path:'tag'},
   {name: 'tagtype', path:'tagtype'}
]

// pug's template
ul
   li(v-for="item in items")
      router-link(active-class="active" v-bind:to="item.to") 

// data
[
  {title: 'tagtype',  to: {name: 'tagtype'}},
  {title: 'tag', to: {name: 'tag'}},
]

The url path /tag '/tagype' will all be actived!
If change tagtype with a different suffix, like atagtype, this bug will be fixed!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions