Add the browser side, built on @sentry/browser. There is no React in Remix 3, so nothing from @sentry/react applies.
- Init plus pageload and navigation tracing driven by the Navigation API. Remix 3 never touches History, so the default browser tracing integration would emit nothing.
- Capture component render errors from the event target
run() returns. The runtime does not rethrow them, so window.onerror cannot see them.
- Ship the
diagnostics_channel shim as its own module. It has to stay a separate file because the browser code transform imports it by URL.
- Export a curated named list instead of
export * from '@sentry/browser', and bundle the client entry into a single tree shaken file.
- Add the size limit budget in the same pull request.
Remix 3 has no bundler, so an unbundled client costs 255 modules and 364 KB gzipped. Bundled it is 2 modules and about 53 KB, against a 54 KB budget for the equivalent browser SDK. The wildcard re-export is what makes tree shaking impossible, and anyone adding one back silently returns us to 364 KB. The budget is the only thing that catches that, which is why it cannot wait for a later pull request.
Done when pageload, navigation and client error e2e tests pass, and the size limit budget is enforced in CI.
Add the browser side, built on
@sentry/browser. There is no React in Remix 3, so nothing from@sentry/reactapplies.run()returns. The runtime does not rethrow them, sowindow.onerrorcannot see them.diagnostics_channelshim as its own module. It has to stay a separate file because the browser code transform imports it by URL.export * from '@sentry/browser', and bundle the client entry into a single tree shaken file.Remix 3 has no bundler, so an unbundled client costs 255 modules and 364 KB gzipped. Bundled it is 2 modules and about 53 KB, against a 54 KB budget for the equivalent browser SDK. The wildcard re-export is what makes tree shaking impossible, and anyone adding one back silently returns us to 364 KB. The budget is the only thing that catches that, which is why it cannot wait for a later pull request.
Done when pageload, navigation and client error e2e tests pass, and the size limit budget is enforced in CI.