How does the secondary page navigation bar of vue highlight?

for example, the navigation bar has two buttons with the following address:

www.xxx.com/page1/A.vue
www.xxx.com/page2/B.vue

at this time, there are secondary pages called A1.vue and B1.vue in An and B

www.xxx.com/page1/subpage1/A1.vue
www.xxx.com/page2/subpage2/B1.vue

clipboard.png

.().


clipboard.png

A1B1,page1page2,,;

is there any way to highlight a child page as soon as it is loaded?


you can configure the routing of this area by using json
such as

{
  name: 'two',
  path: '/two',
  meta: {
    level:'two'
  },
  component: () => import('pages/B.vue')
},

then judge the route through beforeRouterEnter, and then add class
to

<ul>
 <li>
     <nuxt-link to="/subpage1/A">A</nuxt-link>
 </li>
 <li>
     <nuxt-link to="/subpage2/B">B</nuxt-link>
 </li>
</ul>

this also renders dynamically

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