-
Notifications
You must be signed in to change notification settings - Fork 408
feat(clerk-js): Remove BroadcastChannel build variant #7288
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 768e84d The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
WalkthroughRemoved the clerkChannelBrowser build variant and related artifacts; switched BroadcastChannel usage from a build-time flag to runtime environment detection; updated presets, tests, build configs, and type declarations accordingly. Changes
Sequence DiagramsequenceDiagram
participant App as Application
participant TokenCache as TokenCache.ensureBroadcastChannel()
participant Env as Runtime Environment
participant BC as BroadcastChannel API
rect rgb(220,240,255)
note right of TokenCache: Old flow (build-time gated)
App->>TokenCache: Initialize
alt __BUILD_VARIANT_CHANNEL__ true
TokenCache->>BC: instantiate & wire listener
BC-->>TokenCache: ready
else
TokenCache-->>App: null (disabled)
end
end
rect rgb(220,255,220)
note right of TokenCache: New flow (runtime detection)
App->>TokenCache: Initialize
TokenCache->>Env: is BroadcastChannel defined?
alt BroadcastChannel exists
Env-->>TokenCache: yes
TokenCache->>BC: instantiate & wire listener
BC-->>TokenCache: ready
else
Env-->>TokenCache: no
TokenCache-->>App: null (not available)
end
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Disabled knowledge base sources:
📒 Files selected for processing (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (34)
🔇 Additional comments (1)
Comment |
@clerk/agent-toolkit
@clerk/astro
@clerk/backend
@clerk/chrome-extension
@clerk/clerk-js
@clerk/dev-cli
@clerk/elements
@clerk/clerk-expo
@clerk/expo-passkeys
@clerk/express
@clerk/fastify
@clerk/localizations
@clerk/nextjs
@clerk/nuxt
@clerk/clerk-react
@clerk/react-router
@clerk/remix
@clerk/shared
@clerk/tanstack-react-start
@clerk/testing
@clerk/themes
@clerk/types
@clerk/upgrade
@clerk/vue
commit: |
Description
Removing the custom variant for testing out BroadcastChannel functionality. This functionality is now part of the core browser build
Checklist
pnpm testruns as expected.pnpm buildruns as expected.Type of change
Summary by CodeRabbit
Chores
Refactor
Tests
✏️ Tip: You can customize this high-level summary in your review settings.