Skip to content
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

Svelte 5: List of libraries not working out of the box #10359

Open
dummdidumm opened this issue Feb 1, 2024 · 62 comments
Open

Svelte 5: List of libraries not working out of the box #10359

dummdidumm opened this issue Feb 1, 2024 · 62 comments
Labels
Milestone

Comments

@dummdidumm
Copy link
Member

dummdidumm commented Feb 1, 2024

Describe the bug

Some libraries don't work with Svelte 5 out of the box. It will probably be impossible to make every library compatible given that some use stuff svelte/internal (which they really shouldn't) and everything in there changed, but those who don't should be closely investigated. Feel free to post libraries you found that don't work in here, ideally along with a small reproduction (repro or "install and use component X").

Won't / can't fix

Fixed

Reproduction

Use the libraries and observe errors

Logs

No response

System Info

-

Severity

annoyance

@dummdidumm dummdidumm added the bug label Feb 1, 2024
@dummdidumm dummdidumm added this to the 5.0 milestone Feb 1, 2024
@mstachowiak
Copy link

svelte-turnstile breaks as a result of #8301. If that issue is fixed, svelte-turnstile will function properly.

@mstachowiak
Copy link

svelte-confetti has been fixed as of version 1.3.2
Mitcheljager/svelte-confetti#10

@mquandalle

This comment was marked as resolved.

@simeydotme

This comment was marked as resolved.

@dummdidumm dummdidumm pinned this issue Feb 13, 2024
@zhihengGet

This comment was marked as resolved.

@Leftium

This comment was marked as resolved.

@dummdidumm
Copy link
Member Author

svelte-turnstile breaks as a result of #8301. If that issue is fixed, svelte-turnstile will function properly.

@mstachowiak what doesn't work exactly here? #8301 is present in Svelte 4 as well. The library should work since it sets the script tag only after it's mounted. Maybe the cause was #9484 which was fixed by #10416 in the meantime - could you try to reproduce again?

@huntabyte

This comment was marked as resolved.

dummdidumm added a commit that referenced this issue Feb 20, 2024
Adjusts the escaping mechanism done for server compilation. For template literals it's now only applied when explicitly told, which is the case for generated literals from the html template. Fixes a bug where a template literal string inside the `@html` tag was wrongfully escaped (#10359 (comment))
dummdidumm added a commit that referenced this issue Feb 20, 2024
Adjusts the escaping mechanism done for server compilation. For template literals it's now only applied when explicitly told, which is the case for generated literals from the html template. Fixes a bug where a template literal string inside the `@html` tag was wrongfully escaped (#10359 (comment))
@mquandalle

This comment was marked as resolved.

@dummdidumm

This comment was marked as resolved.

@Leftium

This comment was marked as resolved.

@adriandelgado

This comment was marked as resolved.

@ejsmith
Copy link

ejsmith commented Feb 27, 2024

It seems like a ton of libraries are using svelte/internal is there no way to mimic the functionality of the most common things they are doing to greatly reduce the ecosystem fragmentation?

@dit7ya
Copy link

dit7ya commented Feb 27, 2024

TanStack/table#5213. The svelte wrapper for TanStack Table is using svelte/internal and thus is broken.

@vexkiddy

This comment was marked as resolved.

@jakubdonovan
Copy link

svelteflow.dev - the following error occurs as soon as the dep is installed

Error [ERR_UNSUPPORTED_DIR_IMPORT]: Directory import '/home/qw/projects/qwerty/node_modules/.pnpm/@xyflow[email protected][email protected]/node_modules/@xyflow/svelte/dist/lib/container/SvelteFlow' is not supported resolving ES modules imported from /home/sol/projects/qwerty/node_modules/.pnpm/@xyflow[email protected][email protected]/node_modules/@xyflow/svelte/dist/lib/index.js

@huntabyte

This comment was marked as resolved.

@mquandalle

This comment was marked as resolved.

Rich-Harris added a commit that referenced this issue Mar 13, 2024
* fix: handle component binding mutation

#10359 (comment)

* alternative approach to mutating props (#10788)

Co-authored-by: Rich Harris <[email protected]>

---------

Co-authored-by: Rich Harris <[email protected]>
Co-authored-by: Rich Harris <[email protected]>
@manortec

This comment was marked as resolved.

@CaptainCodeman

This comment was marked as resolved.

@vipero07

This comment was marked as resolved.

@CaptainCodeman

This comment was marked as resolved.

@vipero07

This comment was marked as resolved.

@thenbe
Copy link
Contributor

thenbe commented Jun 15, 2024

Svelte wrapper for Tanstack Table, because it uses svelte/internal in a way that can't be backported TanStack/table#5213 - but a new version of the library is underway with Svelte 5 support!

This can be marked as fixed. For now, the fix only exists in the alpha branch (npm i @tanstack/svelte-table@alpha).

@techniq

This comment was marked as resolved.

@dummdidumm

This comment was marked as resolved.

@techniq
Copy link

techniq commented Jun 19, 2024

Wow that was fast @dummdidumm! I updated both Strava and Github analysis and that does appear to fix this issue.

I'm seeing some other issues but I'll investigate and report separately (mostly with a specific chart in Strava Analysis).

CleanShot.2024-06-19.at.15.01.16.2.mp4

Have to run out the door now though.

@jesi-rgb

This comment was marked as resolved.

@7nik

This comment was marked as resolved.

@jesi-rgb

This comment was marked as resolved.

@michealparks
Copy link

michealparks commented Jun 23, 2024

For any Threlte users coming here, there is a next version that is compatible with Svelte 5. See this issue.

@olehmisar
Copy link

@7nik
Copy link

7nik commented Jul 4, 2024

Components no longer being classes is an official breaking change, and Svelte can do nothing here.
Svelte-modals can differentiate components and getters by a number of arguments, which should work in Svelte 3 as well.

@Dudek-AMS
Copy link
Contributor

next.174 broke svelte material ui (SMUI) by @hperrin
hperrin/svelte-material-ui#662

@ghostdevv
Copy link
Member

svelte-turnstile

Just seen this - I took a quick look and it seems as though the key block with $$props in it isn't reactive. I'll try and get some time to make a minimal reproduction. I made an issue on svelte turnstile for tracking - the way I did the reactivity here isn't great anyway and is overdue a change

@Lenostatos

This comment was marked as resolved.

@7nik

This comment was marked as resolved.

@Lenostatos

This comment was marked as resolved.

@Razunter
Copy link

Razunter commented Jul 30, 2024

In my case with [email protected] html elements set with bind:this are undefined in onMount() while in Svelte 4 they are defined at this point. And this breaks a lot of stuff.

UPD: this is with https://github.com/romkor/svelte-portal library, without using portal it works fine. Looks like use: causes this, maybe with async.

@dummdidumm
Copy link
Member Author

Please open a separate issue with a reproduction for this

@josdejong
Copy link
Contributor

First: great work on Svelte 5, I'm looking forward to the release 👍

I'm working on upgrading svelte-jsoneditor to Svelte 5 but there are quite some issues. See the following PR for details: josdejong/svelte-jsoneditor#476

Most important is that the Rollup bundling (for use of the library in a vanilla environment) is broken and Rollup warns about circular references in the svelte code being compiled. Help with the Rollup issues would be great.

Besides that, there are some styling issues and event handlers that are broken now, I can probably get that fixed that myself.

@itswadesh
Copy link

I guess svelte-5 is close to its release. There are only 8 issues left. I have started working towards upgrading svelte-commerce to svelte5

@memestageceo
Copy link

memestageceo commented Sep 15, 2024

Shadcn-svelte Combobox works in Svelte 4, but doesn't in Svelte 5. Tried with both, the code is same in both, the only different is svelte version.

I've created a repo for the same. The svelte 4 works well, svelte 5 fails - keeps adding new items when trying to filter lists

https://github.com/memestageceo/combobox-4v5.git

image

PS: Posting it here as I think that Svelte 5 is meant to be backward compatible, but in this case, it isn't. I don't know how to figure this out more than this, so kindly clone the repo and test it out. I've set up everything for both svelte 4 and svelte 5.

@dummdidumm
Copy link
Member Author

This sounds like huntabyte/cmdk-sv#92, which isn't solveable on our end, and needs adjustment in the library.

@adwher
Copy link

adwher commented Sep 24, 2024

vercel/ai with the @ai-sdk/svelte is not working due they're using svelte/stores, do not work on Runes mode.

Svelte 5: Runes mode

image

image

Svelte 5: Compatibility mode

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests