Skip to content

Commit 7891645

Browse files
Add info on context.ctx argument (vercel#35303)
1 parent 99aea51 commit 7891645

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

docs/advanced-features/custom-app.md

+2
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ The `Component` prop is the active `page`, so whenever you navigate between rout
4040

4141
`pageProps` is an object with the initial props that were preloaded for your page by one of our [data fetching methods](/docs/basic-features/data-fetching/overview.md), otherwise it's an empty object.
4242

43+
The `App.getInitialProps` receives a single argument called `context.ctx`. It's an object with the same set of properties as the [`context` object](/docs/api-reference/data-fetching/get-initial-props#context-object) in `getInitialProps`.
44+
4345
### Caveats
4446

4547
- If your app is running and you added a custom `App`, you'll need to restart the development server. Only required if `pages/_app.js` didn't exist before.

0 commit comments

Comments
 (0)