Skip to content

fix(js): Update denyUrls text in filtering page #13494

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

Merged
merged 1 commit into from
Apr 24, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion docs/platforms/javascript/common/configuration/filtering.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,17 @@ See <PlatformLink to="/configuration/options/#beforeSend">beforeSend</PlatformLi

### Using `allowUrls` and `denyUrls`

You can construct an allowed list of domains for errors. Only errors created within these domains will be captured. For example, if your scripts are loaded from `cdn.example.com` and your site is `example.com`, you can set `allowUrls` to:
You can configure the SDK to avoid sending errors that originate in scripts from certain domains.
For example, if your scripts are loaded from `cdn.example.com` and your site is `example.com`, you can can configure `allowUrls` as follows to avoid capturing errors from other domains:

```javascript
Sentry.init({
allowUrls: [/https?:\/\/((cdn|www)\.)?example\.com/],
});
```

Note that this filters errors based on their stack frames, not the URL of the page where the error occurred.

You can also use `denyUrls` if you want to block errors created on specific URLs from being sent to Sentry.

- See <PlatformLink to="/configuration/options/#allowUrls">allowUrls</PlatformLink> details
Expand Down