From 996e162e42634c22003cce7d654a0b2528a42e71 Mon Sep 17 00:00:00 2001 From: s1gr1d Date: Tue, 5 Aug 2025 10:25:28 +0200 Subject: [PATCH] docs(browser): Delete deprecated `profilesSampler` --- .../_default.mdx | 22 ------------------ .../javascript.angular.mdx | 22 ------------------ .../javascript.astro.mdx | 22 ------------------ .../javascript.electron.mdx | 22 ------------------ .../javascript.nextjs.mdx | 22 ------------------ .../javascript.nuxt.mdx | 22 ------------------ .../javascript.react.mdx | 23 ------------------- .../javascript.remix.mdx | 22 ------------------ .../javascript.svelte.mdx | 22 ------------------ .../javascript.sveltekit.mdx | 22 ------------------ .../javascript.vue.mdx | 22 ------------------ 11 files changed, 243 deletions(-) diff --git a/platform-includes/profiling/automatic-instrumentation-setup/_default.mdx b/platform-includes/profiling/automatic-instrumentation-setup/_default.mdx index 84481e845d33a..730872867b0aa 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/_default.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/_default.mdx @@ -24,25 +24,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript -const Sentry = require("@sentry/browser"); - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.angular.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.angular.mdx index da1878f10e2f9..2052ac5aa68fd 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.angular.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.angular.mdx @@ -24,25 +24,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript -import * as Sentry from "@sentry/angular"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.astro.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.astro.mdx index 39e0b082933d0..7a5e311a77582 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.astro.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.astro.mdx @@ -23,25 +23,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript -import * as Sentry from "@sentry/astro"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.electron.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.electron.mdx index 6cfcbf31f34d3..628bad3fb7440 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.electron.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.electron.mdx @@ -26,25 +26,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript -const Sentry = require("@sentry/electron/renderer"); - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.nextjs.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.nextjs.mdx index d36c29ac402c3..0f37f1508a265 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.nextjs.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.nextjs.mdx @@ -23,25 +23,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript {filename:instrumentation-client.js|ts} -import * as Sentry from "@sentry/nextjs"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.nuxt.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.nuxt.mdx index 8179d0de65365..6818c34e92911 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.nuxt.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.nuxt.mdx @@ -23,25 +23,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript {filename:sentry.client.config.js|ts} -import * as Sentry from "@sentry/nuxt"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.react.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.react.mdx index b3200aa853763..1834744a430ed 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.react.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.react.mdx @@ -24,26 +24,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript -import * as Sentry from "@sentry/react"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.remix.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.remix.mdx index c4bbd438fd13c..54ae801d254ad 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.remix.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.remix.mdx @@ -24,25 +24,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript {filename:entry.client.tsx} -import * as Sentry from "@sentry/remix"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.svelte.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.svelte.mdx index 7267845d4b678..45a0aab1bdd89 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.svelte.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.svelte.mdx @@ -24,25 +24,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript -import * as Sentry from "@sentry/svelte"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.sveltekit.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.sveltekit.mdx index 5e15252624bc0..169635ebd092a 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.sveltekit.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.sveltekit.mdx @@ -23,25 +23,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript {filename:hooks.client.js} -import * as Sentry from "@sentry/sveltekit"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -``` diff --git a/platform-includes/profiling/automatic-instrumentation-setup/javascript.vue.mdx b/platform-includes/profiling/automatic-instrumentation-setup/javascript.vue.mdx index 86dcfb47d9dcc..317f142787d2c 100644 --- a/platform-includes/profiling/automatic-instrumentation-setup/javascript.vue.mdx +++ b/platform-includes/profiling/automatic-instrumentation-setup/javascript.vue.mdx @@ -24,25 +24,3 @@ Sentry.init({ profilesSampleRate: 1.0, }); ``` - -Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function: - -```javascript -import * as Sentry from "@sentry/vue"; - -Sentry.init({ - dsn: "___PUBLIC_DSN___", - integrations: [ - // Add browser profiling integration to the list of integrations - Sentry.browserTracingIntegration(), - Sentry.browserProfilingIntegration(), - ], - tracesSampleRate: 1.0, - - // This function will be called for every sampled span - // to determine if it should be profiled - profilesSampler: (samplingContext) => { - return 1.0; - }, -}); -```