Skip to content

Commit 9b16530

Browse files
committed
get rid of platform includes in node profiling
1 parent 449afbd commit 9b16530

23 files changed

+30
-195
lines changed

docs/platforms/javascript/common/profiling/browser-profiling.mdx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,9 @@ supported:
66
notSupported:
77
- javascript.bun
88
- javascript.cordova
9+
- javascript.capacitor
910
- javascript.deno
1011
- javascript.cloudflare
11-
- javascript.nodejs
12-
- javascript.electron
1312
- javascript.node
1413
- javascript.aws-lambda
1514
- javascript.azure-functions
@@ -65,7 +64,7 @@ For the JavaScript browser profiler to start, the document response header needs
6564

6665
<PlatformContent includePath="profiling/automatic-instrumentation-headers" />
6766

68-
## Step 3: Configure the JavaScript SDK
67+
## Step 3: Configure the <PlatformOrGuideName/> SDK
6968

7069
Configuration should happen as early as possible in your application's lifecycle. Once this is done, Sentry's JavaScript SDK will capture all unhandled exceptions and transactions.
7170

docs/platforms/javascript/common/profiling/index.mdx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22
title: Set Up Profiling
33
sidebar_order: 5000
44
description: "Collect & view performance insights for JavaScript programs with Sentry's Profiling integrations. Get started with browser and Node.js profiling to understand your application's performance."
5+
notSupported:
6+
- javascript.bun
7+
- javascript.cordova
8+
- javascript.capacitor
9+
- javascript.deno
10+
- javascript.cloudflare
511
---
612

713
<PageGrid />

docs/platforms/javascript/common/profiling/node-profiling.mdx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ If you're adopting Profiling in a high-throughput environment, we recommend test
2929

3030
## Installation
3131

32-
<PlatformContent includePath="profiling/node-install" />
32+
Node profiling is available starting in `@sentry/profiling-node` version `0.3.0`.
33+
You have to have the <PlatformSdkPackageName fallback="@sentry/node"/> (minimum version `7.44.1`) package installed.
3334

3435
## Enabling Profiling
3536

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
```bash {tabTitle:npm}
2+
npm install @sentry/astro --save
3+
```
4+
5+
```bash {tabTitle:yarn}
6+
yarn add @sentry/astro
7+
```
8+
9+
```bash {tabTitle:pnpm}
10+
pnpm add @sentry/astro
11+
```

platform-includes/profiling/automatic-instrumentation-setup/javascript.angular.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Sentry.init({
2828
Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function:
2929

3030
```javascript
31-
const Sentry = require("@sentry/angular");
31+
import * as Sentry from "@sentry/angular";
3232

3333
Sentry.init({
3434
dsn: "___PUBLIC_DSN___",

platform-includes/profiling/automatic-instrumentation-setup/javascript.astro.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Sentry.init({
2727
Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function:
2828

2929
```javascript
30-
const Sentry = require("@sentry/astro");
30+
import * as Sentry from "@sentry/astro";
3131

3232
Sentry.init({
3333
dsn: "___PUBLIC_DSN___",

platform-includes/profiling/automatic-instrumentation-setup/javascript.nextjs.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Sentry.init({
2727
Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function:
2828

2929
```javascript {filename:sentry.client.config.js|ts}
30-
const Sentry = require("@sentry/nextjs");
30+
import * as Sentry from "@sentry/nextjs";
3131

3232
Sentry.init({
3333
dsn: "___PUBLIC_DSN___",

platform-includes/profiling/automatic-instrumentation-setup/javascript.nuxt.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Sentry.init({
2727
Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function:
2828

2929
```javascript {filename:sentry.client.config.js|ts}
30-
const Sentry = require("@sentry/nuxt");
30+
import * as Sentry from "@sentry/nuxt";
3131

3232
Sentry.init({
3333
dsn: "___PUBLIC_DSN___",

platform-includes/profiling/automatic-instrumentation-setup/javascript.react.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Sentry.init({
2828
Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function:
2929

3030
```javascript
31-
const Sentry = require("@sentry/react");
31+
import * as Sentry from "@sentry/react";
3232

3333
Sentry.init({
3434
dsn: "___PUBLIC_DSN___",

platform-includes/profiling/automatic-instrumentation-setup/javascript.remix.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Sentry.init({
2828
Alternatively, instead of a `profilesSampleRate` your can also provide a `profilesSampler` function:
2929

3030
```javascript {filename:entry.client.tsx}
31-
const Sentry = require("@sentry/remix");
31+
import * as Sentry from "@sentry/remix";
3232

3333
Sentry.init({
3434
dsn: "___PUBLIC_DSN___",

0 commit comments

Comments
 (0)