Next.js Discord

Discord Forum

Nested Navigation for Mobile but Columns for Desktop

Unanswered
Basset Fauve de Bretagne posted this in #help-forum
Open in Discord
Avatar
Basset Fauve de BretagneOP
I have the following navigation structure for an app that I implemented mobile first.
/list
- page
- /[id]
- - page

For the desktop version I want those two pages to be side by side.
How would you go about implementing this?
Image

1 Reply

Avatar
Basset Fauve de BretagneOP
I decided to use two different components for the /list/page.tsx page depending on the user agent.
Theoretically a desktop user could directly navigate to list/[id]/page.tsx but I think there is no issue with that.
Open for more suggestions.