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

Setting child&children path '/childpath' will not work but works without '/' #2

Closed
shocklinbaubau opened this issue Feb 3, 2019 · 1 comment

Comments

@shocklinbaubau
Copy link

When I need a path: /campaign/example-base

This works:
VueTidyRoutes.route('/campaign', { component: () => import('./views/TheCampaignLayout.vue'), children: { 'example-base': { component: () => import(./templates/example-base/App.vue) } } })

This do not work:
VueTidyRoutes.route('/campaign', { component: () => import('./views/TheCampaignLayout.vue'), children: { '/example-base': { component: () => import(./templates/example-base/App.vue) } } })

And also
This works:
VueTidyRoutes.route('/campaign').child('example-base', { component: () => import(./templates/example-base/App.vue), children: ExampleBaseTemplateRoutes })

This do not work
VueTidyRoutes.route('/campaign').child('/example-base', { component: () => import(./templates/example-base/App.vue), children: ExampleBaseTemplateRoutes })

Please update document, this typo has eaten me a day.

@edgarnadal
Copy link
Owner

Thanks for your report! I just published v0.1.4 fixing this and now it will work.

@shocklinbaubau shocklinbaubau changed the title Document misleading: child/children name should remove '/' Setting child&children path '/childpath' will not work but works without '/' Feb 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants