File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -472,9 +472,10 @@ export class IsomorphicClerk implements IsomorphicLoadedClerk {
472472
473473 if ( ! clerk . loaded ) {
474474 this . beforeLoad ( clerk ) ;
475- // Only load UI scripts in standard browser environments (not native/headless)
476- const shouldLoadUi = ! this . options . Clerk && this . options . standardBrowser !== false ;
477- const ClerkUI = shouldLoadUi ? await this . getClerkUIEntryChunk ( ) : this . options . ui ?. ClerkUI ;
475+ // Load UI in standard browser environments, or when a bundled ClerkUI is provided via the ui prop
476+ const shouldLoadUi =
477+ this . options . standardBrowser !== false && ( ! this . options . Clerk || this . options . ui ?. ClerkUI ) ;
478+ const ClerkUI = shouldLoadUi ? await this . getClerkUIEntryChunk ( ) : undefined ;
478479 await clerk . load ( { ...this . options , ui : { ...this . options . ui , ClerkUI } } ) ;
479480 }
480481 if ( clerk . loaded ) {
You can’t perform that action at this time.
0 commit comments