-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
getsentry/sentry-docs
#5342Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
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).
TS2345: Argument of type '{ dsn: string; }' is not assignable to parameter of type 'BrowserClientOptions'. Type '{ dsn: string; }' is missing the following properties from type 'BrowserClientOptions': integrations, transport, stackParser