From 89b88ee0eadc4faead60e6a8548757b1751a23b3 Mon Sep 17 00:00:00 2001 From: Zack Tanner <1939140+ztanner@users.noreply.github.com> Date: Thu, 18 Apr 2024 13:59:29 -0700 Subject: [PATCH] docs: fix default.js params example (#64748) The `params` example in the docs for `default.js` have the slot/params in the wrong order, giving the impression that you can deeply nest `default` slots. This clarifies that the params received by a slot are based on the dynamic params leading up to the segment containing the slot. Fixes #64708 Closes NEXT-3160 --- docs/02-app/02-api-reference/02-file-conventions/default.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/02-app/02-api-reference/02-file-conventions/default.mdx b/docs/02-app/02-api-reference/02-file-conventions/default.mdx index e80b06713afe2..b1275af15d817 100644 --- a/docs/02-app/02-api-reference/02-file-conventions/default.mdx +++ b/docs/02-app/02-api-reference/02-file-conventions/default.mdx @@ -35,5 +35,5 @@ An object containing the [dynamic route parameters](/docs/app/building-your-appl | Example | URL | `params` | | ------------------------------------------ | ------------ | ----------------------------------- | -| `app/@sidebar/[artist]/default.js` | `/zack` | `{ artist: 'zack' }` | -| `app/@sidebar/[artist]/[album]/default.js` | `/zack/next` | `{ artist: 'zack', album: 'next' }` | +| `app/[artist]/@sidebar/default.js` | `/zack` | `{ artist: 'zack' }` | +| `app/[artist]/[album]/@sidebar/default.js` | `/zack/next` | `{ artist: 'zack', album: 'next' }` |