#404 on Dynamic Routes

2 messages · Page 1 of 1 (latest)

cerulean geyser
#

Hi everyone,

I am an experienced web dev but new to Next.js, specifically the SSR aspect.

I am trying to create a master/detail view with a list of entitlements on the left hand side and entitlement detail on the right hand side.

The entitlement detail will only be displayed when an item in the list is clicked.

I am using dynamic routes with the app router to achieve this.

Example:
/entitlements/[id]

When I am at the route /entitlements and click a <Link> tag to navigate to /entitlements/1 it works as expected.

When I enter /entitlements/1 directly into the url bar I get a 404.

I think I am missing something simple but can’t find it documented anywhere.

Any help would be much appreciated.

kindred quarryBOT
#

🔎 This post has been indexed in our web forum and will be seen by search engines so other users can find it outside Discord

      🕵️ Your user profile is private by default and won't be visible to users outside Discord, if you want to be visible in the web forum you can add the "Public Profile" role in <id:customize>

      ✅ You can mark a message as the answer for your post with `Right click -> Apps -> Mark Solution`
      (if you don't see the option, try refreshing Discord with Ctrl + R)