Skip to content

Fix: Can't find BrowserTransportOptions type#934

Merged
lucas-zimerman merged 2 commits intomainfrom
lz/fix/transport-ref
Jul 10, 2025
Merged

Fix: Can't find BrowserTransportOptions type#934
lucas-zimerman merged 2 commits intomainfrom
lz/fix/transport-ref

Conversation

@lucas-zimerman
Copy link
Collaborator

@lucas-zimerman lucas-zimerman commented Jul 10, 2025

On strict builds, the original reference of BrowserTransportOptions is not accepted.

By using Parameters<typeof makeFetchTransport>[0] we are able to get the original type of BrowserTransportOptions while keeping it compatible with strict builds of Typescript.

Same fix already exists on React Native: https://github.com/getsentry/sentry-react-native/blob/ffab99479d130e00dec3443403629a9a99f29a64/packages/core/src/js/options.ts#L11

Fixes: #933

@lucas-zimerman lucas-zimerman requested a review from antonis July 10, 2025 11:18
Copy link
Contributor

@antonis antonis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀

@lucas-zimerman lucas-zimerman merged commit ded3b9a into main Jul 10, 2025
16 checks passed
@lucas-zimerman lucas-zimerman deleted the lz/fix/transport-ref branch July 10, 2025 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Can't find BrowserTransportOptions type

2 participants