免责声明:我've searched many sites and tried out multiple things from documentation, but i'我只是没弄错 . 请不要仅仅因为这一点而投票,谢谢 .

我喜欢使用多个名称 router-views ,以便我可以将一些组件渲染到它们中 . 我希望能够在父路由中为命名的路由器视图定义一些组件,并在子路由中添加更多(或覆盖它们)f.e:

{
  path: '/'
  components: {
    content: componentA,
  },
  children: [
    {
      path: 'somePath',
      components: {
        toolbar: componentB
      }
    }
  ]
}

现在在somePath中,只有渲染的东西是工具栏routerView中的componentB .

我的问题:

  • 是否有可能以某种方式“扩展”子路径中的组件集?

  • 我是否正确, router-views 只能是兄弟姐妹?你可以't nest them? Or is nesting router-views a way to achieve what i'米试着吗?如果's the case, couldn'找到足够的解释,请提供一些链接 .