Packages

@sentry/wasm

11.10.0 · 28 Oct 2026MIT31.3k / weekRepositoryHomepagenpmAtom feed

Your version

8.7.0

29 May 2024Where it was published

8.55.2 is the newest release of 8.x.

In short

4 new4 fixed1 internal

Release note

Important Changes

  • react: Add TanStack Router integration

    This release adds instrumentation for TanStack router with a new tanstackRouterBrowserTracingIntegration in the
    @sentry/react SDK:

    import * as Sentry from '@sentry/react';
    import { createRouter } from '@tanstack/react-router';
    
    const router = createRouter({
      // Your router options...
    });
    
    Sentry.init({
      dsn: '___PUBLIC_DSN___',
      integrations: [Sentry.tanstackRouterBrowserTracingIntegration(router)],
      tracesSampleRate: 1.0,
    });

Other Changes

  • nextjs: Do not hide sourceMappingURL comment on client when nextConfig.productionBrowserSourceMaps: true is
    set (#12278)

8.6.0 did not release fully, so this 8.7.0 also includes changes from that release.

Important Changes

  • metrics: Add timings method to metrics

    This introduces a new method, metrics.timing(), which can be used in two ways:

    1. With a numeric value, to simplify creating a distribution metric. This will default to second as unit:

    Sentry.metrics.timing('myMetric', 100);
    1. With a callback, which will wrap the duration of the callback. This can accept a sync or async callback. It will
      create an inactive span around the callback and at the end emit a metric with the duration of the span in seconds:

    const returnValue = Sentry.metrics.timing('myMetric', measureThisFunction);
  • react: Add Sentry.reactErrorHandler

    This PR introduces Sentry.reactErrorHandler, which you can use in React 19 as follows:

    import * as Sentry from '@sentry/react';
    import { hydrateRoot } from 'react-dom/client';
    
    ReactDOM.hydrateRoot(
      document.getElementById('root'),
      <React.StrictMode>
        <App />
      </React.StrictMode>,
      {
        onUncaughtError: Sentry.reactErrorHandler(),
        onCaughtError: Sentry.reactErrorHandler((error, errorInfo) => {
          // optional callback if users want custom config.
        }),
      },
    );

    For more details, take a look at the PR. Our
    documentation will be updated soon!

Other Changes

  • sveltekit: Add request data to server-side events

  • core: Pass in cron monitor config correctly

  • nextjs: Don't capture suspense errors in server components

  • tracing: Ensure sent spans are limited to 1000

Bundle size

PathSize
@sentry/browser21.74 KB
@sentry/browser (incl. Tracing)32.73 KB
@sentry/browser (incl. Tracing, Replay)68.3 KB
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags61.62 KB
@sentry/browser (incl. Tracing, Replay with Canvas)72.36 KB
@sentry/browser (incl. Tracing, Replay, Feedback)84.44 KB
@sentry/browser (incl. Tracing, Replay, Feedback, metrics)86.29 KB
@sentry/browser (incl. metrics)25.91 KB
@sentry/browser (incl. Feedback)37.86 KB
@sentry/browser (incl. sendFeedback)26.32 KB
@sentry/browser (incl. FeedbackAsync)30.83 KB
@sentry/react24.51 KB
@sentry/react (incl. Tracing)35.78 KB
@sentry/vue25.72 KB
@sentry/vue (incl. Tracing)34.57 KB
@sentry/svelte21.87 KB
CDN Bundle23.11 KB
CDN Bundle (incl. Tracing)34.46 KB
CDN Bundle (incl. Tracing, Replay)68.39 KB
CDN Bundle (incl. Tracing, Replay, Feedback)73.53 KB
CDN Bundle - uncompressed68 KB
CDN Bundle (incl. Tracing) - uncompressed102.1 KB
CDN Bundle (incl. Tracing, Replay) - uncompressed212 KB
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed224.37 KB
@sentry/nextjs (client)35.12 KB
@sentry/sveltekit (client)33.36 KB
@sentry/node115.24 KB
@sentry/aws-serverless103.73 KB