-
Notifications
You must be signed in to change notification settings - Fork 282
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
Headless error - loaded without UI components #1919
Comments
In this case, you'd need to not use the headless version, as that version is shipped without UI components, hence the naming "headless". We do certainly need to add documentation on this though, we will get it on our list! |
Another thing to add (that is also missing from the docs, we'll work on it!) is that we'll only import the used components (not the full bundle). So tools that statically analyze packages can't know that. |
Thanks @jescalan and @LekoArts. I have another question if you don't mind.
Thank you! |
|
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Preliminary Checks
I have reviewed the documentation: https://clerk.com/docs
I have searched for existing issues: https://github.com/clerkinc/javascript/issues
I have not already reached out to Clerk support via email or Discord (if you have, no need to open an issue here)
This issue is not a question, general help request, or anything other than a bug report directly related to Clerk. Please ask questions in our Discord community: https://clerk.com/discord.
Reproduction / Replay Link
https://stackblitz.com/edit/vitejs-vite-1h7w8x
Publishable key
pk_test_Z29yZ2VvdXMtZmluY2gtMjQuY2xlcmsuYWNjb3VudHMuZGV2JA
Description
I'm trying to use Clerk with a vanilla Vite project and decided to go with the headless version since the normal one's build size is too big. Everything works until I use a method like
openSignIn
. I get theClerkJS was loaded without UI components.
error:Steps to reproduce:
clerk.openSignIn()
call.Expected behavior:
It should open the signin popup, like what it does when using
@clerk/clerk-js
instead of@clerk/clerk-js/headless
.Actual behavior:
Popup not opening and is throwing an error.
How can I make sure that Clerk has been loaded with the UI components when using the headless version?
Environment
The text was updated successfully, but these errors were encountered: