Skip to content

Commit

Permalink
fix(tracing): Export BrowserTracing directly in CDN bundle (#4570)
Browse files Browse the repository at this point in the history
When we made the changes in #4204 (to export `BrowserTracing` directly rather than as part of `Sentry.Integrations`), we didn't make the change in the tracing CDN bundle. While It's true that there's no bundle size issue there (mongo and friends never were getting included in the CDN bundle, so there was nothing to fix), it did mean that when we changed the docs to match the above PR's changes, we ended up breaking CDN folks' usage of `BrowserTracing`.

This fixes that by making the same change in the tracing CDN bundle as was made for the npm package.

Fixes getsentry/sentry-docs#4722.
  • Loading branch information
lobsterkatie authored Feb 14, 2022
1 parent 2a150ee commit 9e87bf9
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/tracing/src/index.bundle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,11 @@ const INTEGRATIONS = {
};

export { INTEGRATIONS as Integrations };
// Though in this case exporting this separately in addition to exporting it as part of `Sentry.Integrations` doesn't
// gain us any bundle size advantage (we're making the bundle here, not the user, and we can't leave anything out of
// ours), it does bring the API for using the integration in line with that recommended for users bundling Sentry
// themselves.
export { BrowserTracing };

// We are patching the global object with our hub extension methods
addExtensionMethods();
Expand Down

0 comments on commit 9e87bf9

Please sign in to comment.