#Layouts and Pathless Routes

6 messages · Page 1 of 1 (latest)

wintry marten
#

Tried to read the docs for multiple times but cant seem to figure out a "perfect" way to do what i want with file + flat router structure ( in the image attached )

Probably a router question move if this is not the right fit here

  • So i want a pathless _dashboard to gate all the auth stuff and show the actual "private" layout, all good here.
  • Then i want bookmarks to be the index, that lists all the items.
  • After i want bookmarks/create or bookmarks/$id to open as a overlay of the index. On the client i can open this correctly and does what i need, but when doing SSR it pushes me back to bookmarks with no redirects :p pretty weird.

Tried also:

_dashboard
-- bookmarks.tsx
-- bookmarks.$id.tsx
-- bookmarks.create.tsx

Any help is appreciated how to make this in a clean way :p

warm saffron
#

How is the navigation done? (Modal opening)

wintry marten
#

Just a link component

strange hawk
#

modals are not well supported at the moment with routes

#

this will be much easier once we have parallel routes

#

right now I would render the modal depending on a search param