-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Required BrowserClientOptions properties contradict Troubleshooting documentation #5298
Comments
Update: This is actually documented in release notes for version 7 at... So the remaining issue is to align the Sentry documentation with the implementation. You can no longer invoke BrowserClient as... const client = new BrowserClient({
dsn: "https://db2c7b7ca7654a14b47912ee3ef4a2c5@o30291.ingest.sentry.io/262607",
}); |
Hi @cefn and thanks for reporting. Yes, as you already found out, we changed the ClientOptions and documented the change in several places, including the release notes/migration guide. But you are completely right, we forgot to update the docs in the Troubleshooting page. Will do this soon. |
This is intentional API change, as manual usage of the client also requires users to opt-in to what dependencies they want (stacktrace parser, transport, integrations). This was essential for us to enable tree shaking, so we decided to do it this way. |
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which package are you using?
@sentry/browser
SDK Version
7.2.0
Framework Version
No response
Link to Sentry event
No response
Steps to Reproduce
The minimal invocation of BrowserClient (passing just the
dsn
in the options as demonstrated in the Javascript documentation) is a compiler error in Typescript. It suggests the Typescript types don't align with actual usage.See also the discussion topic at #5293
Expected Result
The call to BrowserClient demonstrated in the Javascript documentation does compile in Typescript.
Actual Result
This is the compiler error you get when passing just a
dsn
option (as per the reference example in the Sentry documentation).The text was updated successfully, but these errors were encountered: