Parallel route slots
What you need to know
Parallel routes let one layout render several named route regions at once. A folder such as @sidebar supplies a layout prop named sidebar; it does not add a URL segment. This suits a workspace that shows a main reading list alongside a separate activity region.
By the end, you can: map named slots and children; explain independent navigation.
Workspace route tree
app/workspace/ layout.tsx page.tsx default.tsx @activity/page.tsx @activity/default.tsxExpected behavior (not framework-tested): /workspace can render the ordinary page and the activity page together. There is no public /workspace/@activity URL.
How it works
Every layout already receives an implicit children slot. Named slots are passed alongside it and may have their own route subtrees, loading files and error boundaries. The router can retain the active subpage of an unmatched slot during client navigation. On a full load, that remembered state is unavailable; supply default.tsx for each named slot requiring a fallback, and for the implicit children slot when it can be unmatched. In the Next.js 16 lane, missing a required default file can fail the build, not merely produce a runtime 404. Decide whether the default should render a neutral panel or call notFound(), and verify both hard and soft navigation. This is not a promise that multiple data operations always execute concurrently; it is a routing and composition feature. For two fixed panels without independent routing needs, ordinary components may be simpler.
app/workspace/layout.tsx
import type { ReactNode } from "react";export default function Layout({ children, activity }: { children: ReactNode; activity: ReactNode }) { return <div><section aria-label="Reading list">{children}</section> <aside aria-label="Activity">{activity}</aside></div>;}Expected behavior (not framework-tested): The ordinary content and activity region appear under the same layout. If a slot is never rendered, its UI is absent even when its files exist.
Common mistake
Do not add @activity to href. Do not use a slot as an authorization boundary: any private content still requires a server-side access check. Give regions independent fallbacks only when it improves the experience.
Practice and verification
Plan a workspace with a reading queue and an activity panel. Decide whether the panel actually needs its own navigable subpages. Identify every layout prop and the URL corresponding to its files.
Scope: App Router, proposed Next.js 16.x, Cache Components disabled for these labs. Snippets assume a reviewed TypeScript app and are static examples; framework behavior has not been executed. Exact supported patch and dependency set must be verified before running.