React Router Development
remix-run/react-router
Guides work on React Router apps by first identifying whether the app uses Framework, Data or Declarative mode, then loading the matching reference and the installed package docs.
Full Sentry SDK setup for React. An agent skill from getsentry/sentry-for-ai.
$ npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install getsentry/sentry-for-ai sentry-react-sdk --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/getsentry/sentry-for-ai.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills-legacy/sentry-react-sdk .claude/skills/sentry-react-sdk && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "sentry-react-sdk" agent skill from https://github.com/getsentry/sentry-for-ai/tree/main/skills-legacy/sentry-react-sdk into .claude/skills/sentry-react-sdk/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sentry-react-sdk", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/getsentry/sentry-for-ai/tree/main/skills-legacy/sentry-react-sdkType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install getsentry/sentry-for-ai sentry-react-sdk --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/getsentry/sentry-for-ai.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills-legacy/sentry-react-sdk .agents/skills/sentry-react-sdk && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "sentry-react-sdk" agent skill from https://github.com/getsentry/sentry-for-ai/tree/main/skills-legacy/sentry-react-sdk into .agents/skills/sentry-react-sdk/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sentry-react-sdk", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install getsentry/sentry-for-ai sentry-react-sdk --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/getsentry/sentry-for-ai.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills-legacy/sentry-react-sdk .cursor/skills/sentry-react-sdk && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "sentry-react-sdk" agent skill from https://github.com/getsentry/sentry-for-ai/tree/main/skills-legacy/sentry-react-sdk into .cursor/skills/sentry-react-sdk/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sentry-react-sdk", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/getsentry/sentry-for-ai.git --path skills-legacy/sentry-react-sdk--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install getsentry/sentry-for-ai sentry-react-sdk --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/getsentry/sentry-for-ai.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills-legacy/sentry-react-sdk .gemini/skills/sentry-react-sdk && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "sentry-react-sdk" agent skill from https://github.com/getsentry/sentry-for-ai/tree/main/skills-legacy/sentry-react-sdk into .gemini/skills/sentry-react-sdk/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sentry-react-sdk", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install getsentry/sentry-for-ai sentry-react-sdkInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/getsentry/sentry-for-ai.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills-legacy/sentry-react-sdk .github/skills/sentry-react-sdk && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "sentry-react-sdk" agent skill from https://github.com/getsentry/sentry-for-ai/tree/main/skills-legacy/sentry-react-sdk into .github/skills/sentry-react-sdk/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sentry-react-sdk", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install getsentry/sentry-for-ai sentry-react-sdk --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/getsentry/sentry-for-ai.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills-legacy/sentry-react-sdk .opencode/skills/sentry-react-sdk && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "sentry-react-sdk" agent skill from https://github.com/getsentry/sentry-for-ai/tree/main/skills-legacy/sentry-react-sdk into .opencode/skills/sentry-react-sdk/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "sentry-react-sdk", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
sentry-react-sdkFull Sentry SDK setup for React. An agent skill from getsentry/sentry-for-ai.
Sentry React SDK is an agent skill from getsentry/sentry-for-ai, published by the product's own GitHub organization. Full Sentry SDK setup for React. Use when asked to "add Sentry to React", "install @sentry/react", or configure error monitoring, tracing, session replay, profiling, or logging for React applications. Supports React 16+, React Router v5-v7 non-framework mode, TanStack Router, Redux, Vite, and webpack.
Its SKILL.md is about 4.8k tokens, which your agent loads only when the skill is triggered. The skill folder holds 7 other files, including reference files (for example `references/error-monitoring.md`, `references/logging.md` and `references/profiling.md`).
It sits in Frontend & Design, covering State management. It works with Sentry, React, React Router and Redux. The repository describes itself as: Teach your AI coding assistant how to use Sentry - setup, debugging, alerts, and more. The licence is Apache-2.0.
4 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit d8fd106. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
npmFrom the folder's file list and the shell code blocks in SKILL.md.
Hosts in commands or code, which the agent is likely to contact:
docs.sentry.ioFrom URLs in SKILL.md, links to its own repository left out.
Names these keys or tokens, usually read from environment variables:
SENTRY_AUTH_TOKENFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Sentry React SDK loads about 4.8k tokens when it runs, and up to ~54k if it reads all its reference files. Until then it costs about 80 tokens; SKILL.md has 1,291 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from getsentry/sentry-for-ai at commit d8fd106, republished under its Apache-2.0 licence (© getsentry). 1,291 words, ~4,788 tokens.
.claude/skills/sentry-react-sdk/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.All Skills > SDK Setup > React SDK
Opinionated wizard that scans your React project and guides you through complete Sentry setup.
@sentry/react, React Sentry SDK, or Sentry error boundariesIf project is React Router Framework mode using @sentry/react-router, use sentry-react-router-framework-sdk instead of this skill.
Note: SDK versions and APIs below reflect current Sentry docs at time of writing (
@sentry/react≥8.0.0). Always verify against docs.sentry.io/platforms/javascript/guides/react/ before implementing.
Run these commands to understand the project before making any recommendations:
# Detect React version
cat package.json | grep -E '"react"|"react-dom"'
# Check for existing Sentry
cat package.json | grep '"@sentry/'
# Detect router and framework mode hints
cat package.json | grep -E '"react-router-dom"|"react-router"|"@react-router/"|"@tanstack/react-router"|"@sentry/react-router"'
# Detect state management
cat package.json | grep -E '"redux"|"@reduxjs/toolkit"'
# Detect build tool
ls vite.config.ts vite.config.js webpack.config.js craco.config.js 2>/dev/null
cat package.json | grep -E '"vite"|"react-scripts"|"webpack"'
# Detect logging libraries
cat package.json | grep -E '"pino"|"winston"|"loglevel"'
# Check for companion backend in adjacent directories
ls ../backend ../server ../api 2>/dev/null
cat ../go.mod ../requirements.txt ../Gemfile ../pom.xml 2>/dev/null | head -3What to determine:
| Question | Impact |
|---|---|
| React 19+? | Use reactErrorHandler() hook pattern |
| React <19? | Use Sentry.ErrorBoundary |
@sentry/react already present? | Skip install, go straight to feature config |
React Router Framework mode indicators (@sentry/react-router, @react-router/*)? | Use sentry-react-router-framework-sdk |
react-router-dom v5 / v6 / v7? | Determines which router integration to use |
@tanstack/react-router? | Use tanstackRouterBrowserTracingIntegration() |
| Redux in use? | Recommend createReduxEnhancer() |
| Vite detected? | Source maps via sentryVitePlugin |
CRA (react-scripts)? | Source maps via @sentry/webpack-plugin in CRACO |
| Backend directory found? | Trigger Phase 4 cross-link suggestion |
Present a concrete recommendation based on what you found. Don't ask open-ended questions — lead with a proposal:
Recommended (core coverage):
Optional (enhanced observability):
Sentry.logger.*; recommend when structured log search is neededRecommendation logic:
| Feature | Recommend when... |
|---|---|
| Error Monitoring | Always — non-negotiable baseline |
| Tracing | Always for React SPAs — page load + navigation spans are high-value |
| Session Replay | User-facing app, login flows, or checkout pages |
| Logging | App needs structured log search or log-to-trace correlation |
| Profiling | Performance-critical app; server sends Document-Policy: js-profiling header |
React-specific extras:
reactErrorHandler() on createRootsentry-react-router-framework-sdkcreateReduxEnhancer() to Redux storesentryVitePlugin for source maps (essential for readable stack traces)Propose: "I recommend setting up Error Monitoring + Tracing + Session Replay. Want me to also add Logging or Profiling?"
npm install @sentry/react --savesrc/instrument.tsSentry must initialize before any other code runs. Put Sentry.init() in a dedicated sidecar file:
import * as Sentry from "@sentry/react";
Sentry.init({
dsn: import.meta.env.VITE_SENTRY_DSN, // Adjust per build tool (see table below)
environment: import.meta.env.MODE,
release: import.meta.env.VITE_APP_VERSION, // inject at build time
dataCollection: {
// To disable sending user data and HTTP bodies, uncomment the lines below. For more info visit:
// https://docs.sentry.io/platforms/javascript/guides/react/configuration/options/#dataCollection
// userInfo: false,
// httpBodies: [],
},
integrations: [
Sentry.browserTracingIntegration(),
Sentry.replayIntegration({
maskAllText: true,
blockAllMedia: true,
}),
],
// Tracing
tracesSampleRate: 1.0, // lower to 0.1–0.2 in production
tracePropagationTargets: ["localhost", /^https:\/\/yourapi\.io/],
// Session Replay
replaysSessionSampleRate: 0.1,
replaysOnErrorSampleRate: 1.0,
enableLogs: true,
});DSN environment variable by build tool:
| Build Tool | Variable Name | Access in code |
|---|---|---|
| Vite | VITE_SENTRY_DSN | import.meta.env.VITE_SENTRY_DSN |
| Create React App | REACT_APP_SENTRY_DSN | process.env.REACT_APP_SENTRY_DSN |
| Custom webpack | SENTRY_DSN | process.env.SENTRY_DSN |
Import instrument.ts as the very first import in your entry file:
// src/main.tsx (Vite) or src/index.tsx (CRA/webpack)
import "./instrument"; // ← MUST be first
import { StrictMode } from "react";
import { createRoot } from "react-dom/client";
import App from "./App";
createRoot(document.getElementById("root")!).render(
<StrictMode>
<App />
</StrictMode>
);React 19+ — use reactErrorHandler() on createRoot:
import { reactErrorHandler } from "@sentry/react";
createRoot(document.getElementById("root")!, {
onUncaughtError: reactErrorHandler(),
onCaughtError: reactErrorHandler(),
onRecoverableError: reactErrorHandler(),
}).render(<App />);React <19 — wrap your app in Sentry.ErrorBoundary:
import * as Sentry from "@sentry/react";
createRoot(document.getElementById("root")!).render(
<Sentry.ErrorBoundary fallback={<p>Something went wrong</p>} showDialog>
<App />
</Sentry.ErrorBoundary>
);Use <Sentry.ErrorBoundary> for any sub-tree that should catch errors independently (route sections, widgets, etc.).
Configure the matching integration for your router (non-framework mode):
| Router | Integration | Notes |
|---|---|---|
| React Router v7 | reactRouterV7BrowserTracingIntegration | useEffect, useLocation, useNavigationType, createRoutesFromChildren, matchRoutes from react-router |
| React Router v6 | reactRouterV6BrowserTracingIntegration | useEffect, useLocation, useNavigationType, createRoutesFromChildren, matchRoutes from react-router-dom |
| React Router v5 | reactRouterV5BrowserTracingIntegration | Wrap routes in withSentryRouting(Route) |
| TanStack Router | tanstackRouterBrowserTracingIntegration(router) | Pass router instance — no hooks required |
| No router / custom | browserTracingIntegration() | Names transactions by URL path |
React Router v6/v7 setup:
// in instrument.ts integrations array:
import React from "react";
import {
createRoutesFromChildren, matchRoutes,
useLocation, useNavigationType,
} from "react-router-dom"; // or "react-router" for v7
import * as Sentry from "@sentry/react";
import { reactRouterV6BrowserTracingIntegration } from "@sentry/react";
import { createBrowserRouter } from "react-router-dom";
// Option A — createBrowserRouter (recommended for v6.4+):
const sentryCreateBrowserRouter = Sentry.wrapCreateBrowserRouterV6(createBrowserRouter);
const router = sentryCreateBrowserRouter([...routes]);
// Option B — createBrowserRouter for React Router v7:
// const sentryCreateBrowserRouter = Sentry.wrapCreateBrowserRouterV7(createBrowserRouter);
// Option C — integration with hooks (v6 without data APIs):
Sentry.init({
integrations: [
reactRouterV6BrowserTracingIntegration({
useEffect: React.useEffect,
useLocation,
useNavigationType,
matchRoutes,
createRoutesFromChildren,
}),
],
});TanStack Router setup:
import { tanstackRouterBrowserTracingIntegration } from "@sentry/react";
// Pass your TanStack router instance:
Sentry.init({
integrations: [tanstackRouterBrowserTracingIntegration(router)],
});import * as Sentry from "@sentry/react";
import { configureStore } from "@reduxjs/toolkit";
const store = configureStore({
reducer: rootReducer,
enhancers: (getDefaultEnhancers) =>
getDefaultEnhancers().concat(Sentry.createReduxEnhancer()),
});Without source maps, stack traces show minified code. Set up the build plugin to upload source maps automatically:
Vite (vite.config.ts):
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";
import { sentryVitePlugin } from "@sentry/vite-plugin";
export default defineConfig({
build: { sourcemap: "hidden" },
plugins: [
react(),
sentryVitePlugin({
org: process.env.SENTRY_ORG,
project: process.env.SENTRY_PROJECT,
authToken: process.env.SENTRY_AUTH_TOKEN,
}),
],
});Create React App (via CRACO):
npm install @craco/craco @sentry/webpack-plugin --save-dev// craco.config.js
const { sentryWebpackPlugin } = require("@sentry/webpack-plugin");
module.exports = {
webpack: {
plugins: {
add: [
sentryWebpackPlugin({
org: process.env.SENTRY_ORG,
project: process.env.SENTRY_PROJECT,
authToken: process.env.SENTRY_AUTH_TOKEN,
}),
],
},
},
};SENTRY_ORG / SENTRY_PROJECT / SENTRY_AUTH_TOKEN are build-time values; the auth token is a secret (never commit it). For creating the token and wiring it into CI, see sentry-source-maps.
Walk through features one at a time. Load the reference file, follow its steps, verify before moving on:
| Feature | Reference | Load when... |
|---|---|---|
| Error Monitoring | ${SKILL_ROOT}/references/error-monitoring.md | Always (baseline) |
| Tracing | ${SKILL_ROOT}/references/tracing.md | SPA navigation / API call tracing |
| Session Replay | ${SKILL_ROOT}/references/session-replay.md | User-facing app |
| Logging | ${SKILL_ROOT}/references/logging.md | Structured log search / log-to-trace |
| Profiling | ${SKILL_ROOT}/references/profiling.md | Performance-critical app |
| React Features | ${SKILL_ROOT}/references/react-features.md | Redux, component tracking, source maps, integrations catalog |
For each feature: Read ${SKILL_ROOT}/references/<feature>.md, follow steps exactly, verify it works.
Sentry.init() Options| Option | Type | Default | Notes |
|---|---|---|---|
dsn | string | — | Required. SDK disabled when empty |
environment | string | "production" | e.g., "staging", "development" |
release | string | — | e.g., "my-app@1.0.0" or git SHA — links errors to releases |
dataCollection | object | conservative unless set | Fine-grained control over auto-collected categories (userInfo, cookies, httpHeaders, httpBodies, queryParams, genAI). When omitted, the SDK falls back to sendDefaultPii (default false). Passing the object — even {} — flips unset categories to their permissive defaults; opt out per category. |
tracesSampleRate | number | — | 0–1; 1.0 in dev, 0.1–0.2 in prod |
tracesSampler | function | — | Per-transaction sampling; overrides rate |
tracePropagationTargets | (string|RegExp)[] | — | Outgoing URLs that receive distributed tracing headers |
replaysSessionSampleRate | number | — | Fraction of all sessions recorded |
replaysOnErrorSampleRate | number | — | Fraction of error sessions recorded |
enableLogs | boolean | false | Enable Sentry.logger.* API |
attachStacktrace | boolean | false | Stack traces on captureMessage() calls |
maxBreadcrumbs | number | 100 | Breadcrumbs stored per event |
debug | boolean | false | Verbose SDK output to console |
tunnel | string | — | Proxy URL to bypass ad blockers |
dataCollection Options (SDK ≥10.57.0)Fine-grained control over what data the SDK collects. Collection is on by default (with sensitive-value scrubbing); opt out per category:
| Field | Type | Default | Notes |
|---|---|---|---|
userInfo | boolean | true | Collect user id, email, and IP |
cookies | boolean | { allow: string[] } | { deny: string[] } | true | Cookie collection and filtering; true = all cookies (sensitive keys filtered) |
httpHeaders.request | boolean | { allow: string[] } | { deny: string[] } | true | HTTP request header collection |
httpHeaders.response | boolean | { allow: string[] } | { deny: string[] } | true | HTTP response header collection |
queryParams | boolean | { allow: string[] } | { deny: string[] } | true | Query parameter collection and filtering |
httpBodies | HttpBodyCollectionTarget[] | ["incomingRequest", "outgoingRequest", "incomingResponse", "outgoingResponse"] | Collect request/response bodies; options: 'incomingRequest', 'outgoingRequest', 'incomingResponse', 'outgoingResponse' |
genAI.inputs | boolean | true | Record AI model inputs (for AI monitoring) |
genAI.outputs | boolean | true | Record AI model outputs (for AI monitoring) |
stackFrameVariables | boolean | true | Capture local variable values in stack frames |
frameContextLines | number | 5 | Source code context lines around stack frames |
Example: Allow only specific cookies and headers:
Sentry.init({
dataCollection: {
cookies: { allow: ['session', 'user_id'] },
httpHeaders: {
request: { allow: ['authorization', 'x-request-id'] },
response: { deny: ['set-cookie'] },
},
},
});| React Version | Error handling approach | SDK minimum |
|---|---|---|
| React 19+ | reactErrorHandler() on createRoot | @sentry/react ≥8.0.0 |
| React 16–18 | Sentry.ErrorBoundary component | @sentry/react ≥7.0.0 |
| React 16 | componentDidCatch class boundaries | @sentry/react ≥6.0.0 |
Trigger test events to confirm Sentry is receiving data:
// Add a temporary test button anywhere in your app
import * as Sentry from "@sentry/react";
function SentryTest() {
return (
<>
<button onClick={() => { throw new Error("Sentry React test error"); }}>
Test Error
</button>
<button onClick={() => Sentry.captureMessage("Sentry test message", "info")}>
Test Message
</button>
</>
);
}Check the Sentry dashboard:
Set debug: true in Sentry.init() and check the browser console if nothing appears.
After completing React setup, check for a companion backend missing Sentry coverage:
ls ../backend ../server ../api ../go ../python 2>/dev/null
cat ../go.mod 2>/dev/null | head -3
cat ../requirements.txt ../pyproject.toml 2>/dev/null | head -3
cat ../Gemfile 2>/dev/null | head -3
cat ../pom.xml 2>/dev/null | grep '<artifactId>' | head -3If a backend exists without Sentry configured, suggest the matching skill:
| Backend detected | Suggest skill |
|---|---|
Go (go.mod) | sentry-go-sdk |
Python (requirements.txt, pyproject.toml) | sentry-python-sdk |
Ruby (Gemfile) | sentry-ruby-sdk |
Java (pom.xml, build.gradle) | Use @sentry/java — see docs.sentry.io/platforms/java/ |
| Node.js (Express, Fastify) | Use @sentry/node — see docs.sentry.io/platforms/javascript/guides/express/ |
| Issue | Solution |
|---|---|
| Events not appearing | Set debug: true, check DSN, open browser console for SDK errors |
| Source maps not working | Build in production mode (npm run build); verify SENTRY_AUTH_TOKEN is set |
| Minified stack traces | Source maps not uploading — check plugin config and auth token |
instrument.ts not running first | Verify it's the first import in entry file before React/app imports |
| React 19 errors not captured | Confirm reactErrorHandler() is passed to all three createRoot options |
| React <19 errors not captured | Ensure <Sentry.ErrorBoundary> wraps the component tree |
Router transactions named <unknown> | Add router integration matching your router version |
tracePropagationTargets not matching | Check regex escaping; default is localhost and your DSN origin only |
| Session replay not recording | Confirm replayIntegration() is in init; check replaysSessionSampleRate |
| Redux actions not in breadcrumbs | Add Sentry.createReduxEnhancer() to store enhancers |
| Ad blockers dropping events | Set tunnel: "/sentry-tunnel" and add server-side relay endpoint |
| High replay storage costs | Lower replaysSessionSampleRate; keep replaysOnErrorSampleRate: 1.0 |
| Profiling not working | Verify Document-Policy: js-profiling header is set on document responses |
© getsentry, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 6 other files (references) in skills-legacy/sentry-react-sdk of getsentry/sentry-for-ai.
Open the folder on GitHubat commit d8fd106
Sentry React SDK next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Sentry React SDK this skillgetsentry/sentry-for-ai | 268 | — | ~4.8k | Automated safety check: Pass | Apache-2.0 | |
| React Router Developmentremix-run/react-router | 57k | 1 repos | ~1.5k | Automated safety check: Pass | MIT | |
| Cursor BYOK Frontend Guideleookun/cursor-byok | 3.2k | — | ~1.9k | Automated safety check: Pass | MIT | |
| Local Testinglobehub/lobe-ui | 2.2k | — | ~2.1k | Automated safety check: Pass | MIT | |
| Using Docs Kitlobehub/lobe-ui | 2.2k | — | ~2.8k | Automated safety check: Pass | MIT | |
| Feature Sliced Designfeature-sliced/skills | 109 | — | ~5.5k | Automated safety check: Pass | None |
remix-run/react-router
Guides work on React Router apps by first identifying whether the app uses Framework, Data or Declarative mode, then loading the matching reference and the installed package docs.
leookun/cursor-byok
Sets the rules for building the Cursor BYOK desktop app's React and Tauri frontend, especially its HTTP boundary and component state architecture.
lobehub/lobe-ui
Local browser verification for the lobe-ui component library and documentation site.
lobehub/lobe-ui
Set up and author a documentation site with @lobehub/docs-kit (the lobedocs CLI, React Router + Vite static docs used by ui.lobehub.com).
feature-sliced/skills
Official Feature-Sliced Design (FSD) v2.1 skill for applying the methodology to frontend projects.
geekskai/blog
React SPA auth patterns with @clerk/react for Vite/CRA - ClerkProvider setup, useAuth/useUser/useClerk hooks, React Router protected routes, custom sign-in flows.
getsentry/sentry-for-ai
Full Sentry SDK setup for Elixir. An agent skill from getsentry/sentry-for-ai.
getsentry/sentry-for-ai
Full Sentry SDK setup for Go. An agent skill from getsentry/sentry-for-ai.
getsentry/sentry-for-ai
Full Sentry SDK setup for Next.js. An agent skill from getsentry/sentry-for-ai.
getsentry/sentry-for-ai
Full Sentry SDK setup for PHP. An agent skill from getsentry/sentry-for-ai.
getsentry/sentry-for-ai
Full Sentry SDK setup for Python. An agent skill from getsentry/sentry-for-ai.
getsentry/sentry-for-ai
Full Sentry SDK setup for React Router Framework mode. An agent skill from getsentry/sentry-for-ai.
Categories
Full Sentry SDK setup for React. An agent skill from getsentry/sentry-for-ai. Sentry React SDK is an agent skill from getsentry/sentry-for-ai, published by the product's own GitHub organization. Full Sentry SDK setup for React.
Sentry React SDK fits situations like: asked to add Sentry to React; install @sentry/react; configure error monitoring; logging for React applications.
Run `npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a claude-code`. Or copy the skill folder (skills-legacy/sentry-react-sdk in getsentry/sentry-for-ai) into .claude/skills/sentry-react-sdk in your project. Claude Code loads it when a task matches its description.
Run `npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a codex`. Or copy the skill folder (skills-legacy/sentry-react-sdk in getsentry/sentry-for-ai) into .agents/skills/sentry-react-sdk in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add getsentry/sentry-for-ai --skill sentry-react-sdk -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/sentry-react-sdk, .gemini/skills/sentry-react-sdk, .github/skills/sentry-react-sdk and .opencode/skills/sentry-react-sdk in your project.
Going by SKILL.md and its folder, Sentry React SDK needs the command-line tools its instructions call (npm) and credentials named SENTRY_AUTH_TOKEN. Our summary lists: Node.js; A credential in SENTRY_AUTH_TOKEN.
SKILL.md names 1 domain. In commands or code: docs.sentry.io; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Sentry React SDK is published under the Apache-2.0 licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.
About 4.8k tokens (SKILL.md is roughly 19k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 50k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Sentry React SDK: React Router Development (remix-run/react-router, 57k stars), Cursor BYOK Frontend Guide (leookun/cursor-byok, 3.2k stars), Local Testing (lobehub/lobe-ui, 2.2k stars) and Using Docs Kit (lobehub/lobe-ui, 2.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
getsentry (a GitHub organization, an official publisher) maintains it in getsentry/sentry-for-ai, which has 268 GitHub stars. The repository holds 32 skills in this directory. The repository was last updated on October 7, 2026.
Source: getsentry/sentry-for-ai on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.