Interactions for React Router Framework

Capture clicks and the work they trigger as browser spans.

Import name: Sentry.interactionsIntegration

The Interactions integration captures clicks and the work they trigger as spans. Use it with BrowserTracing or your framework's routing integration to associate interactions with the current route.

Copied
Sentry.init({
  integrations: [
    Sentry.browserTracingIntegration(),
    Sentry.interactionsIntegration(),
  ],
});

Clicks outside an active pageload or navigation start an interaction span. Requests and other spans started during the interaction become its children. The integration also captures individual clicks.

INP is collected by the WebVitals integration and does not require this integration.

These timeouts apply to interaction spans, independently of BrowserTracing's pageload and navigation timeouts.

idleTimeout

Typenumber
Default1000

Time in milliseconds to wait before finishing an interaction span when no unfinished child spans remain.

finalTimeout

Typenumber
Default30000

Maximum duration of an interaction span in milliseconds, including time spent waiting for child spans.

childSpanTimeout

Typenumber
Default15000

Maximum time in milliseconds a child span can run before the interaction span finishes.

Was this helpful?
Help improve this content
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").