Skip to content

Commit fb372e8

Browse files
Luca Forstnershanamatthews
andcommitted
Add docs for AggregateErrors in Node.js and Browser (#7499)
Co-authored-by: Shana Matthews <[email protected]>
1 parent 867ea51 commit fb372e8

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

src/includes/platforms/configuration/integrations/default.mdx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,14 +89,16 @@ Available options:
8989

9090
_Import name: `Sentry.Integrations.LinkedErrors`_
9191

92-
This integration allows you to configure linked errors. They’ll be recursively read up to a specified limit, and lookup will be performed by a specific key. By default, the Sentry SDK sets the limit to five and the key used is `"cause"`.
92+
This integration allows you to configure linked errors. They'll be recursively read up to a specified limit, and a lookup will be performed by a specific key on the captured Error object. By default, the integration records up to five errors and the key used for recursion is `"cause"`.
93+
94+
This integration also enhances captured error events with data from an [AggregateError](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/AggregateError) where applicable, by recursively iterating over the `errors` property on Error objects.
9395

9496
Available options:
9597

9698
```javascript
9799
{
98-
key: string;
99-
limit: number;
100+
key: string; // default: "cause"
101+
limit: number; // default: 5
100102
}
101103
```
102104

src/platforms/node/common/configuration/integrations/default-integrations.mdx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@ are wrapped by our error or breadcrumb handlers.
3131

3232
_Import name: `Sentry.Integrations.LinkedErrors`_
3333

34-
This integration allows you to configure linked errors. They'll be recursively read up to a specified limit, and lookup will be performed by a specific key. By default, the limit is set to `5` and the key used is `"cause"`.
34+
This integration allows you to configure linked errors. They'll be recursively read up to a specified limit, and a lookup will be performed by a specific key on the captured Error object. By default, the integration records up to five errors and the key used for recursion is `"cause"`.
35+
36+
This integration also enhances captured error events with data from an [AggregateError](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/AggregateError) where applicable, by recursively iterating over the `errors` property on Error objects.
3537

3638
Available options:
3739

0 commit comments

Comments
 (0)