[go: nahoru, domu]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Improve error handling docs #67332

Merged
merged 2 commits into from
Jul 1, 2024
Merged

docs: Improve error handling docs #67332

merged 2 commits into from
Jul 1, 2024

Conversation

leerob
Copy link
Member
@leerob leerob commented Jul 1, 2024

Based on this discussion: #62681

@ijjk ijjk added created-by: Next.js DevEx team Documentation Related to Next.js' official documentation. labels Jul 1, 2024
- For errors forwarded from Client Components, this will be the original Error's message.
- For errors forwarded from Server Components, this will be a generic error message to avoid leaking sensitive details. `errors.digest` can be used to match the corresponding error in server-side logs.
- Errors forwarded from Client Components show the original `Error` message.
- Errors forwarded from Server Components show a generic message with an identifier. This is to prevent leaking sensitive details. You can use the identifier, under `errors.digest`, to match the corresponding server-side logs.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we ever explain how you'd match up client and server errors with errors.digest?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good suggestion, maybe we can include more details here.

@leerob leerob merged commit 0115636 into canary Jul 1, 2024
35 checks passed
@leerob leerob deleted the error-docs branch July 1, 2024 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
created-by: Next.js DevEx team Documentation Related to Next.js' official documentation.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants