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

Different layout for nested routes. #120

Closed
matpulis opened this issue Sep 6, 2023 · 3 comments
Closed

Different layout for nested routes. #120

matpulis opened this issue Sep 6, 2023 · 3 comments

Comments

@matpulis
Copy link

matpulis commented Sep 6, 2023

I am trying to set the layout from a nested page and it's not working for me. What I would like to do is use a different layout in pages under the same folder. Layouts only work if its declared in the first file in the pages directory.

This Works ,but both my nested routes get the same layout.
-[src]
-- [pages]
--- profiles.vue [Layout 1]
--- [profiles]
---- view.vue
---- create.vue

Not Working
-[src]
-- [pages]
--- [profiles]
---- view.vue [Layout 1]
---- create.vue [Layout 2]

Am I missing something here or is this intended behavior?

@PWie
Copy link

PWie commented Oct 3, 2023

Same for me - I guess that in current implementation only root level pages can have layout defined.
Would be nice to have it improved to allow using different layouts for nested routes.

@kalaomer
Copy link

I need the same feature, root level is ok but some scenarios this is not enough :/

@JohnCampionJr
Copy link
Owner

For the record this is related to #78 - new route structure

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

4 participants