✨ NextJS Add addNextJSError component#4289
✨ NextJS Add addNextJSError component#4289BeltranBulbarellaDD wants to merge 19 commits intomainfrom
Conversation
|
@codex pls review |
|
✅ Tests 🎉 All green!❄️ No new flaky tests detected 🎯 Code Coverage (details) 🔗 Commit SHA: 9080b6f | Docs | Datadog PR Page | Was this helpful? React with 👍/👎 or give us feedback! |
Bundles Sizes Evolution
🚀 CPU PerformancePending... 🧠 Memory PerformancePending... |
|
@codex pls review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a6c24fa210
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: aecc13fe47
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: thomas.bertet <thomas.bertet@datadoghq.com>
…computation (#4227) Co-authored-by: thomas.bertet <thomas.bertet@datadoghq.com>
|
I have read the CLA Document and I hereby sign the CLA 5 out of 6 committers have signed the CLA. |
e366c1e to
9080b6f
Compare
Motivation
Discussed in this RFC specifically here
Changes
(AI written)
Add
addNextjsError(error, context?)to@datadog/browser-rum-nextjs. This is the integration point for reporting errors caught by Next.js error boundaries (error.tsx/global-error.tsx) to Datadog RUM.addNextjsError— wrapspublicApi.addErrorwith:framework: 'nextjs'context.nextjs.digestcontext when the error has a digest (server component errors) — this hash links client-side errors to server-side logsgetGlobalPublicApi()getter added tonextjsPlugin.tsto expose the RUM public API@datadog/browser-rum-nextjsmain entryerror.tsxandglobal-error.tsxaddNextjsError, server component that throws, andglobal-error.tsxTest instructions
(AI written)
yarn test:unit --spec packages/rum-nextjs/src/domain/addNextjsError.spec.ts(6 specs)yarn test:e2e -g "addNextjsError"(2 scenarios — client error + server error with digest)React StrictModedouble-firesuseEffectin dev mode, so E2E tests assert >= 1 custom errors rather than exactly 1Checklist