feat: add sentry

This commit is contained in:
Tony Yang
2025-04-17 00:36:59 +08:00
parent d3ea3c33b8
commit c3df80671a
4 changed files with 44 additions and 1 deletions
+11
View File
@@ -0,0 +1,11 @@
import * as Sentry from "@sentry/cloudflare";
export const onRequest = [
Sentry.sentryPagesPlugin((context) => ({
dsn: "https://9d2c460f5e6bca67a47fa821860dceef@o4506857623453696.ingest.us.sentry.io/4509163928944640",
// Set tracesSampleRate to 1.0 to capture 100% of spans for tracing.
// Learn more at
// https://docs.sentry.io/platforms/javascript/configuration/options/#traces-sample-rate
tracesSampleRate: 1.0,
}))
];