Next.js Discord

Discord Forum

Revalidation break intercepted routes

Unanswered
KAM posted this in #help-forum
Open in Discord
KAMOP
Reproduction :
- navigate to an intercepted route
- use a server action that revalidatepath

expected :
data is revalidated while on the intercepted page.

actual :
When you perform an action that revalidates the path or a tag, the intercepted route is destroyed and you return to the root page.

What's more, the route page's server component seems to run synchronously, whereas it has been defined as asynchronous, which causes data inconsistencies.

is it expected ? is it a known bug ?

5 Replies

KAMOP
@KAM ok there is a commit for this FYI: https://github.com/vercel/next.js/pull/59585#issue-2039989880
Yellowstripe scad
Is it fixed? I still have this problem... Did you manage it other way?
Tbh, my current approach was to use searchParams to open a modal, this way server actions don't break. But i wanted to use the new intercepted routes for this
@Yellowstripe scad Is it fixed? I still have this problem... Did you manage it other way?
KAMOP
Nop, the problem is still there, I also use searchParams to open a functional modal
I guess parallel routes are not the priority at the moment.