/**
 * Sentry (Glitchtip-compatible) client-side init. Loaded by Next.js
 * automatically when @sentry/nextjs is installed.
 */
import * as Sentry from "@sentry/nextjs";

const dsn = process.env.NEXT_PUBLIC_SENTRY_DSN;
if (dsn) {
  Sentry.init({
    dsn,
    environment: process.env.NODE_ENV || "development",
    tracesSampleRate: 0,
    sendDefaultPii: false,
    // Capture unhandled promise rejections + JS errors. Glitchtip community
    // ignores everything below `error` severity by default.
  });
}
