Skip to content

docs: Add Deno import example for Supabase integration#17562

Open
cursor[bot] wants to merge 2 commits intomasterfrom
cursor/docs-feedback-processing-500d
Open

docs: Add Deno import example for Supabase integration#17562
cursor[bot] wants to merge 2 commits intomasterfrom
cursor/docs-feedback-processing-500d

Conversation

@cursor
Copy link
Copy Markdown
Contributor

@cursor cursor Bot commented Apr 30, 2026

DESCRIBE YOUR PR

Addresses user feedback from docs.sentry.io (DOCS-ANT).

  • Added a Deno-specific configuration section to the Supabase integration page showing the correct npm:@sentry/deno import before the Supabase import
  • The existing snippet (for non-Deno platforms) is preserved unchanged under a PlatformSection notSupported guard
  • Fixed a minor typo in the Configuration section intro ("most use cases. and" → "most use cases and")

IS YOUR CHANGE URGENT?

  • None: Not urgent, can wait up to 1 week+

PRE-MERGE CHECKLIST

  • Checked Vercel preview for correctness, including links
  • PR was reviewed and approved by any necessary SMEs
  • PR was reviewed and approved by a member of the docs team
Open in Web View Automation 

…gration

The Supabase integration page's configuration snippet did not show
the Sentry import statement. For Deno users, the import syntax is
unique (npm: prefix) and must come before other imports for correct
instrumentation. Add a PlatformSection with a Deno-specific example
showing the correct import order.

Also fix minor typo in the configuration section intro sentence.

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: Sergiy Dybskiy <s@serg.tech>
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 30, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
sentry-docs Ready Ready Preview, Comment Apr 30, 2026 3:39pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
develop-docs Ignored Ignored Preview Apr 30, 2026 3:39pm

Request Review

@sergical
Copy link
Copy Markdown
Member

@cursoragent we have a pattern for dynamically importing the right version of the SDK import in other places, can we do that instead of just doing the Deno SDK? That snippet has a Sentry.init in it, so we need all configurations for the supabase integration to also import Sentry from the SDK package for the platform this page is being served on

@cursor
Copy link
Copy Markdown
Contributor Author

cursor Bot commented Apr 30, 2026

  • Implemented: Updated the Supabase integration docs to use our dynamic SDK import pattern.
  • Change: Non-Deno block now imports Sentry via the platform-aware placeholder; Deno keeps the explicit npm import.

Code reference:

import * as Sentry from "___SDK_PACKAGE___";
import { createClient } from '@supabase/supabase-js';

const supabaseClient = createClient('YOUR_SUPABASE_URL', 'YOUR_SUPABASE_KEY');

Sentry.init({
  dsn: 'YOUR_DSN',
  integrations: [
    Sentry.supabaseIntegration({ supabaseClient })
  ],

Status: Committed and pushed to cursor/docs-feedback-processing-500d. The Deno section continues to use import * as Sentry from 'npm:@sentry/deno' before other imports.

  • Added dynamic ___SDK_PACKAGE___ import to ensure Sentry.init resolves the correct SDK per platform.
  • Preserved and clarified the Deno-specific snippet using npm:@sentry/deno (first import).
Open in Web Open in Cursor 

…to non-Deno config so pulls the correct SDK per platform. Keep Deno-specific import and ensure it appears before other imports.\n\nRefs DOCS-ANT\nCo-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: Sergiy Dybskiy <s@serg.tech>
@sergical
Copy link
Copy Markdown
Member

@cursoragent do we need the specific deno callout to yield the two separate platform includes blocks, feels redundant, no?

@cursor
Copy link
Copy Markdown
Contributor Author

cursor Bot commented Apr 30, 2026

Short answer: yes — we need the Deno-specific block.

Reason:

  • The dynamic placeholder (SDK_PACKAGE) resolves to @sentry/deno, but Deno requires the npm: prefix (npm:@sentry/deno).
  • Deno also needs npm:@supabase/supabase-js, which differs from other platforms.

Because our current placeholder system doesn’t add npm: for Deno, a single unified snippet would be copy/paste-wrong for Deno. Keeping two minimal PlatformSection blocks ensures both variants are correct and ready to paste.

If you want to de-duplicate, we’d need a new placeholder (e.g., SDK_IMPORT_PATH and SUPABASE_IMPORT_PATH) that renders with npm: for Deno. That’s a small infra change but out of scope for this PR.

Open in Web Open in Cursor 

Copy link
Copy Markdown
Contributor Author

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 9c0689c. Configure here.

});
```

</PlatformSection>
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Duplicated code blocks risk diverging during maintenance

Low Severity

The Deno PlatformSection block duplicates the entire Sentry.init configuration from the non-Deno block, differing only in the import lines. If the init configuration (e.g., integration options, sample rate) is updated in one block, the other can easily be missed, leading to inconsistent documentation. The PR reviewer also flagged this redundancy. Other integration pages like postgresjs.mdx use this pattern but have completely different code per platform — here, the body is identical and only the imports differ.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 9c0689c. Configure here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants