Skip to content
Open
Show file tree
Hide file tree
Changes from 13 commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
7b27cd0
feat: Add `react-router` wizard
onurtemizkan Aug 28, 2025
b454790
Add unit tests
onurtemizkan Aug 28, 2025
1201cf0
Add E2E test app
onurtemizkan Aug 28, 2025
ee8dc4c
Make outputs consistent with the other wizards
onurtemizkan Aug 28, 2025
c8748ad
Add `traceStep`s
onurtemizkan Sep 1, 2025
9d020fb
Fix message in help tests
onurtemizkan Sep 1, 2025
530cf34
Remove unnecessary unit tests
onurtemizkan Sep 1, 2025
7bed296
Add `react-router` to e2e test matrix
onurtemizkan Sep 1, 2025
1903d37
Fix help message
onurtemizkan Sep 1, 2025
60e0469
Remove vite plugin test
onurtemizkan Sep 1, 2025
371dada
Add more sdk-setup unit tests
onurtemizkan Sep 1, 2025
80a9605
Add CHANGELOG entry
onurtemizkan Sep 1, 2025
1034cfc
Clean uo
onurtemizkan Sep 1, 2025
3a1e70f
Use `reactRouterTracingIntegration` and remove unnecessary imports
onurtemizkan Sep 15, 2025
ae7abf7
Remove remix-like hook arguments from `reactRouterTracingIntegration`
onurtemizkan Sep 16, 2025
7325ddb
Show code snippets instead of linking docs
onurtemizkan Sep 16, 2025
f333e76
Prompt to retry reveal if entry files are not found
onurtemizkan Sep 16, 2025
f7494b9
Fix tests
onurtemizkan Sep 16, 2025
8b79577
Clean up
onurtemizkan Sep 16, 2025
6985887
Only show copy-paste instructions on the outer level
onurtemizkan Sep 16, 2025
b92bf72
Improve snippets, cover ts/tsx/mjs extensions
onurtemizkan Sep 17, 2025
b6b5699
Check if `isRouteErrorResponse` already exists before adding import
onurtemizkan Sep 17, 2025
09c6af2
Selectively add type import for `HandleErrorFunction`, check for pote…
onurtemizkan Sep 17, 2025
8ad7ee2
Move instrumentRoot logic to codemod
onurtemizkan Sep 17, 2025
a3695b8
Move handleError logic to codemod
onurtemizkan Sep 17, 2025
326c645
Implement handleRequest logic via codemod
onurtemizkan Sep 18, 2025
0106979
Remove custom express server tests
onurtemizkan Sep 18, 2025
0416cf0
Clean up
onurtemizkan Sep 18, 2025
859dcac
Fix duplicated `captureException`s in ErrorBoundary
onurtemizkan Sep 18, 2025
b113291
Add `package.json` script updates
onurtemizkan Sep 18, 2025
d9294b7
Run prettier
onurtemizkan Sep 18, 2025
c11dddc
Add client-entry codemod
onurtemizkan Sep 19, 2025
8acbdc4
Update e2e tests
onurtemizkan Sep 19, 2025
a6cd632
Add unit tests for codemods
onurtemizkan Sep 19, 2025
4d5fed6
Do not cover `handleError`s exported via object pattern
onurtemizkan Sep 19, 2025
cd7b416
Remove development debug logging
onurtemizkan Sep 19, 2025
fe09a64
Lint
onurtemizkan Sep 21, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,7 @@ jobs:
- NextJS-14
- NextJS-15
- Remix
- React-Router
- React-Native
- Sveltekit-Hooks
- Sveltekit-Tracing
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
## Unreleased

- feat(sveltekit): Add support for SDK setup with `instrumentation.server.ts` ([#1077](https://github.com/getsentry/sentry-wizard/pull/1077))
- feat: Add wizard for react-router framework mode ([#1076](https://github.com/getsentry/sentry-wizard/pull/1076))

This release adds support for setting up the SvelteKit SDK in SvelteKit versions 2.31.0 or higher.

Expand Down
106 changes: 106 additions & 0 deletions e2e-tests/test-applications/react-router-test-app/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
# Dependencies
node_modules/
/.pnp
.pnp.*

# Build outputs
/build
/dist
/.react-router

# Environment variables
.env
.env.local
.env.development.local
.env.test.local
.env.production.local

# Logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Coverage directory used by tools like istanbul
coverage/
*.lcov

# nyc test coverage
.nyc_output

# Dependency directories
node_modules/
jspm_packages/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional stylelint cache
.stylelintcache

# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# parcel-bundler cache (https://parceljs.org/)
.cache
.parcel-cache

# Next.js build output
.next

# Nuxt.js build / generate output
.nuxt
dist

# Storybook build outputs
.out
.storybook-out

# Temporary folders
tmp/
temp/

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

# OS generated files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db

43 changes: 43 additions & 0 deletions e2e-tests/test-applications/react-router-test-app/app/root.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
import {
Links,
Meta,
Outlet,
Scripts,
ScrollRestoration,
} from "react-router";

export default function App() {
return (
<html lang="en">
<head>
<meta charSet="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<Meta />
<Links />
</head>
<body>
<div className="App">
<nav>
<ul>
<li>
<a href="/">Home</a>
</li>
<li>
<a href="/about">About</a>
</li>
<li>
<a href="/contact">Contact</a>
</li>
</ul>
</nav>

<main>
<Outlet />
</main>
</div>
<ScrollRestoration />
<Scripts />
</body>
</html>
);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import type { RouteConfig } from "@react-router/dev/routes";
import { index, route } from "@react-router/dev/routes";

export default [
index("routes/home.tsx"),
route("/about", "routes/about.tsx"),
route("/contact", "routes/contact.tsx"),
] satisfies RouteConfig;
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
export default function About() {
return (
<div>
<h1>About</h1>
<p>This is a test application for React Router.</p>
</div>
);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
export default function Contact() {
return (
<div>
<h1>Contact</h1>
<p>Contact us for more information.</p>
</div>
);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
export default function Home() {
return (
<div>
<h1>Home</h1>
<p>Welcome to the React Router test app!</p>
</div>
);
}
27 changes: 27 additions & 0 deletions e2e-tests/test-applications/react-router-test-app/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"name": "react-router-test-app",
"private": true,
"version": "0.0.0",
"type": "module",
"scripts": {
"build": "react-router build",
"dev": "react-router dev",
"start": "react-router-serve ./build/server/index.js",
"typecheck": "react-router typegen && tsc"
},
"dependencies": {
"@react-router/dev": "^7.8.2",
"@react-router/node": "^7.8.2",
"@react-router/serve": "^7.8.2",
"isbot": "^4.4.0",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"react-router": "^7.8.2"
},
"devDependencies": {
"@types/react": "^18.3.9",
"@types/react-dom": "^18.3.0",
"typescript": "^5.6.2",
"vite": "^6.0.1"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import type { Config } from "@react-router/dev/config";

export default {
// Config options
} satisfies Config;
31 changes: 31 additions & 0 deletions e2e-tests/test-applications/react-router-test-app/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"include": [
"**/*.ts",
"**/*.tsx",
"**/.server/**/*.ts",
"**/.server/**/*.tsx",
"**/.client/**/*.ts",
"**/.client/**/*.tsx"
],
"compilerOptions": {
"lib": ["DOM", "DOM.Iterable", "ES6"],
"isolatedModules": true,
"esModuleInterop": true,
"jsx": "react-jsx",
"module": "ESNext",
"moduleResolution": "Bundler",
"resolveJsonModule": true,
"target": "ES2022",
"strict": true,
"allowJs": true,
"skipLibCheck": true,
"forceConsistentCasingInFileNames": true,
"baseUrl": ".",
"paths": {
"~/*": ["./app/*"]
},

// React Router v7 specific options
"types": ["@react-router/dev"]
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import { reactRouter } from "@react-router/dev/vite";
import { defineConfig } from "vite";

export default defineConfig({
plugins: [reactRouter()],
});
3 changes: 2 additions & 1 deletion e2e-tests/tests/help-message.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ describe('--help command', () => {
-i, --integration Choose the integration to setup
env: SENTRY_WIZARD_INTEGRATION
[choices: "reactNative", "flutter", "ios", "android", "cordova", "angular",
"electron", "nextjs", "nuxt", "remix", "sveltekit", "sourcemaps"]
"electron", "nextjs", "nuxt", "remix", "reactRouter", "sveltekit",
"sourcemaps"]
-p, --platform Choose platform(s)
env: SENTRY_WIZARD_PLATFORM
[array] [choices: "ios", "android"]
Expand Down
Loading
Loading