3👍
✅
UserParent.vue
<template>
<router-view />
</template>
router.js
routes: [
{
path: "/user",
component: UserParent,
children: [
{
path: "/",
name: "user",
component: User
},
{
path: "/settings",
name: "settings",
component: Settings
},
{
path: "/profile",
name: "profile",
component: Profile
}
]
}
]
Source:stackexchange.com