diff --git a/src/wizard/javascript/replay-onboarding/angular/2.configure.md b/src/wizard/javascript/replay-onboarding/angular/2.configure.md index 0167e894eae915..fb734e81ed4ecb 100644 --- a/src/wizard/javascript/replay-onboarding/angular/2.configure.md +++ b/src/wizard/javascript/replay-onboarding/angular/2.configure.md @@ -7,7 +7,7 @@ type: language #### Configure -Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay in our Github [Readme](https://github.com/getsentry/sentry-replay/blob/main/README.md). +Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay by reading the [configuration docs](https://docs.sentry.io/platforms/javascript/guides/angular/session-replay/custom-instrumentation/). ```javascript import * as Sentry from "@sentry/angular"; @@ -15,14 +15,16 @@ import { Replay } from "@sentry/replay"; Sentry.init({ dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], }); ``` diff --git a/src/wizard/javascript/replay-onboarding/ember/2.configure.md b/src/wizard/javascript/replay-onboarding/ember/2.configure.md index 3f5617a2417b02..01685a877207f5 100644 --- a/src/wizard/javascript/replay-onboarding/ember/2.configure.md +++ b/src/wizard/javascript/replay-onboarding/ember/2.configure.md @@ -7,7 +7,7 @@ type: language #### Configure -Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay in our Github [Readme](https://github.com/getsentry/sentry-replay/blob/main/README.md). +Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay by reading the [configuration docs](https://docs.sentry.io/platforms/javascript/guides/ember/session-replay/custom-instrumentation/). ```javascript import * as Sentry from "@sentry/ember"; @@ -15,14 +15,16 @@ import { Replay } from "@sentry/replay"; Sentry.init({ dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], }); ``` diff --git a/src/wizard/javascript/replay-onboarding/gatsby/2.configure.md b/src/wizard/javascript/replay-onboarding/gatsby/2.configure.md index 90a3858937dc86..accadf09a48e6b 100644 --- a/src/wizard/javascript/replay-onboarding/gatsby/2.configure.md +++ b/src/wizard/javascript/replay-onboarding/gatsby/2.configure.md @@ -7,7 +7,7 @@ type: language #### Configure -Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay in our Github [Readme](https://github.com/getsentry/sentry-replay/blob/main/README.md). +Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay by reading the [configuration docs](https://docs.sentry.io/platforms/javascript/guides/gatsby/session-replay/custom-instrumentation/). Include the `@sentry/gatsby` plugin: @@ -29,14 +29,16 @@ import { Replay } from "@sentry/replay"; Sentry.init({ dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], }); ``` diff --git a/src/wizard/javascript/replay-onboarding/nextjs/2.configure.md b/src/wizard/javascript/replay-onboarding/nextjs/2.configure.md index db792f47b50333..9e37f86e1356d2 100644 --- a/src/wizard/javascript/replay-onboarding/nextjs/2.configure.md +++ b/src/wizard/javascript/replay-onboarding/nextjs/2.configure.md @@ -7,7 +7,7 @@ type: language #### Configure -Add the following to your Client SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay in our Github [Readme](https://github.com/getsentry/sentry-replay/blob/main/README.md). +Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay by reading the [configuration docs](https://docs.sentry.io/platforms/javascript/guides/nextjs/session-replay/custom-instrumentation/). ```javascript {filename:sentry.client.config.js} import * as Sentry from "@sentry/nextjs"; @@ -15,14 +15,16 @@ import { Replay } from "@sentry/replay"; Sentry.init({ dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], }); ``` diff --git a/src/wizard/javascript/replay-onboarding/react/2.configure.md b/src/wizard/javascript/replay-onboarding/react/2.configure.md index 01fb0b2ed89aa9..77e43690eaf9a9 100644 --- a/src/wizard/javascript/replay-onboarding/react/2.configure.md +++ b/src/wizard/javascript/replay-onboarding/react/2.configure.md @@ -7,7 +7,7 @@ type: language #### Configure -Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay in our Github [Readme](https://github.com/getsentry/sentry-replay/blob/main/README.md). +Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay by reading the [configuration docs](https://docs.sentry.io/platforms/javascript/guides/react/session-replay/custom-instrumentation/). ```javascript import * as Sentry from "@sentry/react"; @@ -15,14 +15,16 @@ import { Replay } from "@sentry/replay"; Sentry.init({ dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], }); ``` diff --git a/src/wizard/javascript/replay-onboarding/remix/2.configure.md b/src/wizard/javascript/replay-onboarding/remix/2.configure.md index 9d071a546fc154..80d15fcf3e7d78 100644 --- a/src/wizard/javascript/replay-onboarding/remix/2.configure.md +++ b/src/wizard/javascript/replay-onboarding/remix/2.configure.md @@ -7,7 +7,7 @@ type: language #### Configure -Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay in our Github [Readme](https://github.com/getsentry/sentry-replay/blob/main/README.md). +Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay by reading the [configuration docs](https://docs.sentry.io/platforms/javascript/guides/remix/session-replay/custom-instrumentation/). ```javascript {filename: entry.client.tsx} import * as Sentry from "@sentry/remix"; @@ -15,14 +15,16 @@ import { Replay } from "@sentry/replay"; Sentry.init({ dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], }); ``` diff --git a/src/wizard/javascript/replay-onboarding/svelte/2.configure.md b/src/wizard/javascript/replay-onboarding/svelte/2.configure.md index bfa8529e791361..253b9d3b537d90 100644 --- a/src/wizard/javascript/replay-onboarding/svelte/2.configure.md +++ b/src/wizard/javascript/replay-onboarding/svelte/2.configure.md @@ -7,7 +7,7 @@ type: language #### Configure -Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay in our Github [Readme](https://github.com/getsentry/sentry-replay/blob/main/README.md). +Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay by reading the [configuration docs](https://docs.sentry.io/platforms/javascript/guides/svelte/session-replay/custom-instrumentation/). ```javascript import "./app.css"; @@ -18,14 +18,16 @@ import { Replay } from "@sentry/replay"; Sentry.init({ dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], }); diff --git a/src/wizard/javascript/replay-onboarding/vue/2.configure.md b/src/wizard/javascript/replay-onboarding/vue/2.configure.md index 659e14f47d4806..afa4fc9d19bd36 100644 --- a/src/wizard/javascript/replay-onboarding/vue/2.configure.md +++ b/src/wizard/javascript/replay-onboarding/vue/2.configure.md @@ -7,7 +7,7 @@ type: language #### Configure -Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay in our Github [Readme](https://github.com/getsentry/sentry-replay/blob/main/README.md). +Add the following to your SDK config. There are several privacy and sampling options available, all of which can be set via the `integrations` constructor. Learn more about configuring Session Replay by reading the [configuration docs](https://docs.sentry.io/platforms/javascript/guides/vue/session-replay/custom-instrumentation/). #### Vue 2 @@ -26,14 +26,16 @@ const router = new Router({ Sentry.init({ Vue, dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], }); @@ -63,14 +65,16 @@ const router = createRouter({ Sentry.init({ app, dsn: "https://examplePublicKey@o0.ingest.sentry.io/0", - integrations: [ - new Replay({ - // Capture 10% of all sessions - sessionSampleRate: 0.1, - // Of the remaining 90% of sessions, if an error happens start capturing - errorSampleRate: 1.0, - }) + // This sets the sample rate to be 10%. You may want this to be 100% while + // in development and sample at a lower rate in production + replaysSessionSampleRate: 0.1, + // If the entire session is not sampled, use the below sample rate to sample + // sessions when an error occurs. + replaysOnErrorSampleRate: 1.0, + + integrations: [ + new Replay() ], });