Next.js Discord

Discord Forum

Warning: No default component was found for a parallel route rendered on this page.

Unanswered
Yellowfin tuna posted this in #help-forum
Open in Discord
Yellowfin tunaOP
I cannot figure out how to remove this warning. This is my folder structure:
/app
  /help-section
    /[[...slug]]
      page.js
    layout.js
  layout.js
  page.js
  not-found.js

The file /app/help-section/[[...slug]]/page.js calls notFound() whenever you enter a url that is invalid. I'm handling some 10 urls under /help-section, for example:
/help-section/users
/help-section/users/profile
/help-section/admins
/help-section/customers

However if you enter a url such as /help-section/invalid/123/abc which is invalid, the not-found.js is rendered, which is OK. But then also the warning appears in the client console "No default component was found for a parallel route rendered on this page. Falling back to nearest NotFound boundary.". How can I remove this warning?

I tried creating a default.js file in all subfolders, all possible combinations, but to no avail.

6 Replies

Yellowfin tunaOP
@joulev No I don't. I don't have any parallel routes in my project. I'm using Next.js 14.2.31. Here's the folder structure, and the tail contents of /app/(main)/help-center/[[...slug]]/page.js:
@Yellowfin tuna <@484037068239142956> No I don't. I don't have any parallel routes in my project. I'm using Next.js 14.2.31. Here's the folder structure, and the tail contents of **/app/(main)/help-center/[[...slug]]/page.js**:
that looks very odd.

could you try this:
* upgrade nextjs. this could be an old bug of nextjs
* if it doesn't work, pls try to create a minimal reproduction example and send me the github link so i can try it out myself and see what's wrong
@joulev that looks very odd. could you try this: * upgrade nextjs. this could be an old bug of nextjs * if it doesn't work, pls try to create a minimal reproduction example and send me the github link so i can try it out myself and see what's wrong
Yellowfin tunaOP
I'm not ready to update to Next.js 15, since that involves some breaking changes and I would have to revise the whole codebase. However, I might create a minimalistic reproduction example and post it on github.
Yellowfin tunaOP
I actually created a minimal example and couldn't reproduce the bug, using Next 15.5.0. Do you suggest I should always try to keep up with Next.js i.e. try to use the latest version?
yeah that's the ideal course of action. nextjs is buggy and they fix bugs every version. but of course upgrading is not always feasible for reasons i understand

if you can afford the time, do look thru the breaking change list and try to upgrade. i don't remember the breaking changes being too disruptive and they were pretty easy to migrate iirc

if not, one way to figure out what went wrong is to gradually remove parts of the buggy code and see where things start working again