-
Notifications
You must be signed in to change notification settings - Fork 151
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
Error with external Svelte 5 components #655
Comments
The problem is that You can fix this by changing your We should probably also search for a |
Hum... well in my case I already have a tsconfig.json. But the sveltekit project is in a subfolder (in a monorepo without a tsconfig at the root level). Would that trigger the same issue as well? I tried adding a tsconfig.json at the root of the repo, but I get the same issue. |
Does the SvelteKit project in which you have this error have a tsconfig.json? What happens if you set the tsconfigDirectory option? |
Yes it has. |
What error should I be expecting in that stackblitz example? The image loads up and there's no error in the Stackblitz console. |
Oh yeah you are right. I made other tests since the last comment. What you where seeing is when we use the preprocessor from @sveltejs/vite-plugin-svelte. I just modified back to using svelte-preprocess, you should see the error now. Thank you for your help. |
Did you find a solution yet? |
I'm currently experiencing an issue with TailwindCSS v4 which appears to use |
Here's a reproduction @dummdidumm https://github.com/huntabyte/tw-v4-monorepo-repro/tree/main - Does |
To add to this, I'm also experiencing the issue @huntabyte is seeing when trying to set up tailwind v4.0 beta. |
It looks like the specific issue we're running into will be resolved via this PR in Tailwind tailwindlabs/tailwindcss#15274 @sgcullen (they don't need to use the preprocessor). |
Describe the bug
Using svelte-preprocess with Svelte 5 and importing a Svelte 5 component from an npm package triggers an error:
'p' has already been declared
Detailed error with a random package
Same error occurs with bits-ui@next, svelte-clerk...
To Reproduce
I made a simple example here:
https://stackblitz.com/edit/sveltejs-kit-template-default-u71xqf?file=svelte.config.js
Is there a simple way to make it work?
Thank's for your help.
The text was updated successfully, but these errors were encountered: