fix: improve sentry handling + upgrade version

This commit is contained in:
swve 2024-02-04 19:19:32 +01:00
parent 58385e4183
commit 0c6ce121b0
5 changed files with 32 additions and 46 deletions

View file

@ -16,7 +16,7 @@
"@radix-ui/react-icons": "^1.1.1",
"@radix-ui/react-switch": "^1.0.3",
"@radix-ui/react-tooltip": "^1.0.5",
"@sentry/nextjs": "^7.92.0",
"@sentry/nextjs": "^7.93.0",
"@stitches/react": "^1.2.8",
"@tiptap/extension-code-block-lowlight": "^2.1.11",
"@tiptap/extension-collaboration": "^2.0.0-beta.199",

View file

@ -4,8 +4,11 @@
import * as Sentry from "@sentry/nextjs";
if (process.env.NODE_ENV !== "development") {
const DSN = process.env.SENTRY_DSN || process.env.NEXT_PUBLIC_SENTRY_DSN;
Sentry.init({
dsn: "https://5a456d54654c494b9a416c19e3b94573@o4505007882436608.ingest.sentry.io/4505008095625216",
dsn: DSN,
// Adjust this value in production, or use tracesSampler for greater control
tracesSampleRate: 1,
@ -28,3 +31,4 @@ Sentry.init({
}),
],
});
}

View file

@ -1,16 +0,0 @@
// This file configures the initialization of Sentry for edge features (middleware, edge routes, and so on).
// The config you add here will be used whenever one of the edge features is loaded.
// Note that this config is unrelated to the Vercel Edge Runtime and is also required when running locally.
// https://docs.sentry.io/platforms/javascript/guides/nextjs/
import * as Sentry from "@sentry/nextjs";
Sentry.init({
dsn: "https://5a456d54654c494b9a416c19e3b94573@o4505007882436608.ingest.sentry.io/4505008095625216",
// Adjust this value in production, or use tracesSampler for greater control
tracesSampleRate: 1,
// Setting this option to true will print useful information to the console while you're setting up Sentry.
debug: false,
});

View file

@ -4,12 +4,10 @@
import * as Sentry from "@sentry/nextjs";
if (process.env.NODE_ENV !== "development") {
const DSN = process.env.SENTRY_DSN || process.env.NEXT_PUBLIC_SENTRY_DSN;
Sentry.init({
dsn: "https://5a456d54654c494b9a416c19e3b94573@o4505007882436608.ingest.sentry.io/4505008095625216",
// Adjust this value in production, or use tracesSampler for greater control
tracesSampleRate: 1,
// Setting this option to true will print useful information to the console while you're setting up Sentry.
debug: false,
dsn: DSN,
tracesSampleRate: 1.0,
});
}

2
pnpm-lock.yaml generated
View file

@ -42,7 +42,7 @@ importers:
specifier: ^1.0.5
version: 1.0.7(@types/react-dom@18.0.6)(@types/react@18.2.8)(react-dom@18.2.0)(react@18.2.0)
'@sentry/nextjs':
specifier: ^7.92.0
specifier: ^7.93.0
version: 7.93.0(next@14.0.4)(react@18.2.0)
'@stitches/react':
specifier: ^1.2.8