-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Class isn't passed to Svelte island #5397
Comments
The If you want to add in the passed in class you can do so yourself, by getting the class that comes in as a prop and then passing that into your |
Thanks! Learned something new regarding |
I'm not an expert on Svelte but I believe this will work: let className;
export { className as class }; |
Ah, here's a good blogpost on the topic by our very own @tony-sull https://navillus.dev/blog/svelte-class-props |
Awesome, thank you! |
What version of
astro
are you using?1.6.7
Are you using an SSR adapter? If so, which one?
None
What package manager are you using?
npm
What operating system are you using?
Mac
Describe the Bug
The issue #5029 isn't solved as far as I can tell. I also checked if it was included in a release: https://github.com/withastro/astro/releases/tag/%40astrojs%2Fsvelte%401.0.2 & I'm using that version of
@astrojs/svelte
.If I add a class to a Svelte island, I would expect it to be added to the parent element in the component, but this doesn't work right now.
Link to Minimal Reproducible Example
LukaHarambasic/harambasic.de@a792bbf
Participation
The text was updated successfully, but these errors were encountered: