Skip to content

Help me DRY my routes.ts #12690

Closed Answered by sergiodxa
ric980 asked this question in Q&A
Jan 5, 2025 · 3 comments · 2 replies
Discussion options

You must be logged in to vote

If there's a layout that all :lang routes share, then use route to define the parent route and rest of the routes as nested.

If there's no layout and only the URL needs to include the param, use prefix helper.

Replies: 3 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@sergiodxa
Comment options

Answer selected by ric980
Comment options

You must be logged in to vote
1 reply
@sergiodxa
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants