Layouts
Answered
Shaurya posted this in #help-forum
![Avatar](https://cdn.discordapp.com/avatars/893705256368750592/d371def1a743b93f7417007b3e298cfc.webp?size=256)
ShauryaOP
I have a layout which have nav and stuff but I don't want the layout to the login page, how would I do that?
Answered by averydelusionalperson
18 Replies
![Avatar](https://cdn.discordapp.com/avatars/1011594178934878248/8f4b2208d7b55efefe8cac402633bbe5.webp?size=256)
averydelusionalperson
ahh, use route groups
![Avatar](https://cdn.discordapp.com/avatars/743561772069421169/3c5d689eee4459a24fc420063411c016.webp?size=256)
Ray
use route group
(with-nav)/layout.tsx <-- render Nav here
(with-nav)/page.tsx
/login/page.tsx
(with-nav)/layout.tsx <-- render Nav here
(with-nav)/page.tsx
/login/page.tsx
![Avatar](https://cdn.discordapp.com/avatars/1011594178934878248/8f4b2208d7b55efefe8cac402633bbe5.webp?size=256)
averydelusionalperson
shouldn't there be two different route gruops? (with-nav) & (without-nav)?
oh
got it
nvm
![Avatar](https://cdn.discordapp.com/avatars/743561772069421169/3c5d689eee4459a24fc420063411c016.webp?size=256)
Ray
the default one without nav lol
![Avatar](https://cdn.discordapp.com/avatars/893705256368750592/d371def1a743b93f7417007b3e298cfc.webp?size=256)
ShauryaOP
can you please elaborate, didn't understand
this is my structure
this is my structure
![Image](https://cdn.discordapp.com/attachments/1225746391167533108/1225746942517182474/image.png?ex=662240cc&is=660fcbcc&hm=84f5d26745b0b37b7c0c3c4310780c76c666d5ac1460419b2bb113d10723bbe2&)
![Avatar](https://cdn.discordapp.com/avatars/1011594178934878248/8f4b2208d7b55efefe8cac402633bbe5.webp?size=256)
averydelusionalperson
yeah, got confused, I read it like
(with-nav)/page.tsx/login/page.tsx
instead of seperate linescreate a folder named
(with-nav)
, and in that keep your pages with nav bar, and layout with navbar, and outside of that folder keep other pages without those nav bar.![Avatar](https://cdn.discordapp.com/avatars/1011594178934878248/8f4b2208d7b55efefe8cac402633bbe5.webp?size=256)
averydelusionalperson
Answer
![Avatar](https://cdn.discordapp.com/avatars/1011594178934878248/8f4b2208d7b55efefe8cac402633bbe5.webp?size=256)
averydelusionalperson
checkout docs here
![Avatar](https://cdn.discordapp.com/avatars/893705256368750592/d371def1a743b93f7417007b3e298cfc.webp?size=256)
ShauryaOP
so the home page
/app/page.tsx
would be /app/withnav/page.tsx
right?oh
the parentheses
got it, lemme do that
![Avatar](https://cdn.discordapp.com/avatars/1011594178934878248/8f4b2208d7b55efefe8cac402633bbe5.webp?size=256)
averydelusionalperson
yeah, like this 👇
![Image](https://cdn.discordapp.com/attachments/1225746391167533108/1225748373353533500/image.png?ex=66224221&is=660fcd21&hm=d744f7628d711a90938737ded95a2e36f67cfae3446161ddf62c5ecac5b3134c&)
![Avatar](https://cdn.discordapp.com/avatars/893705256368750592/d371def1a743b93f7417007b3e298cfc.webp?size=256)
ShauryaOP
thanks, works perfect, didn't have use of routing groups before