I have this SvelteKit directory setup: routes/(main)/vergabeassistent
.Within that directory I have:
+page.svelte
[slug]/+page.svelte
Calling localhost:5173/vergabeassistent
works fine and is a list view. I now wanted to create slug route for the detail view and the id is a parameter in the url. However, calling localhost:5173/vergabeassistent/SOMEID
is not being found at all. I suspect this may be caused by the fact that I am already withhin a the group route of (main)
?The +page.svelte
of the slug route looks like this:
<script lang="ts"> import type { PageData } from './$types'; export let data: PageData;</script><h1>{data}</h1>
What am I doing wrong?