Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Components for child routes doesn't show #2629

Closed
Ihor-Shevtsov opened this Issue Feb 27, 2019 · 1 comment

Comments

Projects
None yet
2 participants
@Ihor-Shevtsov
Copy link

Ihor-Shevtsov commented Feb 27, 2019

Version

3.0.2

Reproduction link

https://codepen.io/ih-shevtsov/pen/ywNVEe

Steps to reproduce

  1. Click on "Go to nested route 1" -> route changed to /home/nested-route-1
  2. Click on "Go to nested route 2" -> route changed to /home/nested-route-2

What is expected?

Components for specific child route must be shown.

What is actually happening?

Components for child routes doesn't show. It is works only for "parent" route.


I tried to research this issue in router's code. Seems like incorrect router depth for any reason (https://github.com/vuejs/vue-router/blob/v3.0.2/dist/vue-router.esm.js#L58-L69)

@posva

This comment has been minimized.

Copy link
Member

posva commented Feb 27, 2019

This is working as expected, when using children you must nest router-view in your route components and name those accordingly

@posva posva closed this Feb 27, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.