You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 3574e32
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: docs/platforms/javascript/common/configuration/integrations/servetunnel.mdx
+24-2Lines changed: 24 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -32,7 +32,29 @@ Sentry.init({
32
32
33
33
The browser and the server both derive the tunnel path from the DSN, for example `/qpo967`. You don't need a route file, a build step, or an environment variable. If your app is served under a base path, the SDK adds it on both sides.
34
34
35
-
The integration doesn't handle requests by itself. The SvelteKit, Nuxt, Nitro, Astro, React Router (framework mode), TanStack Start, and Remix 3 SDKs serve the tunnel from their request hooks. On other servers, like Express, Fastify, Bun, Deno, or Cloudflare Workers, [serve it yourself](#serving-the-tunnel-yourself).
In framework mode, the SDK serves the tunnel from its request hooks, so this is all the setup you need.
44
+
45
+
</PlatformSection>
46
+
47
+
<PlatformSectionsupported={["javascript.remix"]}>
48
+
49
+
On Remix 3, the SDK serves the tunnel from its request hooks, so this is all the setup you need. On earlier versions, [serve it yourself](#serving-the-tunnel-yourself).
@@ -110,7 +132,7 @@ The path prefix your app is served under, for example `/docs`. The SDK reads it
110
132
111
133
## Serving the Tunnel Yourself
112
134
113
-
On servers without a framework SDK hook, like Express, Fastify, `node:http`, Bun, or Deno, mount `handleTunnelRequestIfMatched` before your routes and body parsers. It forwards tunnel requests and returns `undefined` for everything else:
135
+
On servers without a framework SDK hook, mount `handleTunnelRequestIfMatched` before your routes and body parsers. It forwards tunnel requests and returns `undefined` for everything else:
Copy file name to clipboardExpand all lines: docs/platforms/javascript/common/troubleshooting/index.mdx
+24-2Lines changed: 24 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -228,7 +228,7 @@ You can work around our CDN bundles being blocked by [using our NPM packages](#u
228
228
229
229
<AvailableSinceversion="11.10.0" />
230
230
231
-
The SDK can serve the tunnel for you. Set `tunnel: true` in your browser `Sentry.init`, and add `serveTunnelIntegration` to your server `Sentry.init`:
231
+
Set `tunnel: true` in your browser `Sentry.init`, and add `serveTunnelIntegration` to your server `Sentry.init`:
232
232
233
233
```javascript {tabTitle:Browser}
234
234
Sentry.init({
@@ -246,14 +246,36 @@ Sentry.init({
246
246
247
247
The browser then sends its events to a path on your own origin derived from the DSN, and your server forwards them to Sentry.
248
248
249
-
The SvelteKit, Nuxt, Nitro, Astro, React Router (framework mode), TanStack Start, and Remix 3 SDKs serve the tunnel for you and read your app's base path from your framework config. On other servers, like Express, mount `handleTunnelRequestIfMatched` before your routes and body parsers:
In framework mode, the SDK serves the tunnel for you and reads your app's base path from your framework config. In other modes, see <PlatformLinkto="/configuration/integrations/servetunnel/#serving-the-tunnel-yourself">Serving the Tunnel Yourself</PlatformLink>.
258
+
259
+
</PlatformSection>
260
+
261
+
<PlatformSectionsupported={["javascript.remix"]}>
262
+
263
+
On Remix 3, the SDK serves the tunnel for you and reads your app's base path from your framework config. On earlier versions, see <PlatformLinkto="/configuration/integrations/servetunnel/#serving-the-tunnel-yourself">Serving the Tunnel Yourself</PlatformLink>.
See <PlatformLink to="/configuration/integrations/servetunnel/">`serveTunnelIntegration`</PlatformLink> for a fixed path, more allowed DSNs, and how the tunnel handles requests. If you can't use the managed tunnel, set up your own tunnel as explained below.
0 commit comments