كل حِزم SDK

React Router

v

@sentry/react-router

استخدم حِزمة Sentry الرسمية مع DSN الظاهر في إعداد مشروع AllStak. لا تحتاج إلى حِزمة SDK خاصة بـ AllStak.

التثبيت

تأتي أوامر Sentry الرسمية هذه من سجل حِزم SDK المُدار في AllStak.

npm
npm install @sentry/react-router
pnpm
pnpm add @sentry/react-router
yarn
yarn add @sentry/react-router

البدء السريع

import * as Sentry from "@sentry/browser";

Sentry.init({
  dsn: "{{DSN}}",
  environment: "production",
  release: "[email protected]",
  tracesSampleRate: 1.0,
  replaysSessionSampleRate: 0.1,
  replaysOnErrorSampleRate: 1.0,
  // Off by default. Enable only if you accept sending usernames,
  // emails and IP addresses to your telemetry backend.
  sendDefaultPii: false,
});

Sentry.captureException(new Error("hello from @sentry/browser"));