Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Intercepted page in dynamic route with route groups gets called when linked from another segment #65061

Open
tjabbe opened this issue Apr 25, 2024 · 0 comments
Labels
bug Issue was opened via the bug report template. Parallel & Intercepting Routes Related to Parallel and/or Intercepting routes.

Comments

@tjabbe
Copy link
Contributor

tjabbe commented Apr 25, 2024

Link to the code that reproduces this issue

https://github.com/tjabbe/parallel-intercepting-with-dynamic-route

To Reproduce

  1. Go to https://parallel-intercepting-with-dynamic-route.vercel.app/dynamic-route/list and click on the link
    It will call the intercepted page, which it shouldn't since we're not in the [slug] segment

  2. Go to https://parallel-intercepting-with-dynamic-route.vercel.app/dynamic-route and click on the first link "Single Clip Page"
    it will correctly call the non-intercepted page, which is expected behaviour that I would expect while in /list

Current vs. Expected behavior

I would expect that the non-intercepted page would be called when clicking on a link from another segment, here from /list to [slug]/clips/[id]

Provide environment information

Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 23.4.0: Fri Mar 15 00:12:25 PDT 2024; root:xnu-10063.101.17~1/RELEASE_ARM64_T6030
  Available memory (MB): 36864
  Available CPU cores: 12
Binaries:
  Node: 20.11.1
  npm: 10.2.4
  Yarn: 1.22.21
  pnpm: N/A
Relevant Packages:
  next: 14.3.0-canary.23 // Latest available version is detected (14.3.0-canary.23).
  eslint-config-next: N/A
  react: 18.3.0
  react-dom: 18.3.0
  typescript: 5.1.3
Next.js Config:
  output: N/A

Which area(s) are affected? (Select all that apply)

Parallel & Intercepting Routes

Which stage(s) are affected? (Select all that apply)

next dev (local), next start (local), Vercel (Deployed), Other (Deployed)

Additional context

Hello!

This issue only seems to happen if the intercepting page is called from another segment. It works fine if it's called from the "root" page.

I have also included a static-route example which doesn't use a dynamic route, and it works fine there with the same route groups setup.

Thank you!

@tjabbe tjabbe added the bug Issue was opened via the bug report template. label Apr 25, 2024
@github-actions github-actions bot added the Parallel & Intercepting Routes Related to Parallel and/or Intercepting routes. label Apr 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue was opened via the bug report template. Parallel & Intercepting Routes Related to Parallel and/or Intercepting routes.
Projects
None yet
Development

No branches or pull requests

1 participant