Open mattpilott opened 1 month ago
I'm unable to deploy a svelte kit site on cloudflare when using svelte 5
Is there any minimal reproduction to demonstrate this? a repo should be enough.
Perhaps there is a pee dep update needed?
Perhaps. So far I have been testing phosphor-svelte in conjunction with svelte@^5, and it's working fine. Feel free to open a PR.
PS: I'm testing it by monkey patching the Svelte version in the peerDependencies.
Ok ill make a repro, locally in dev its all great but deploying to either vercel or cloudflare fails
@haruaki07 https://github.com/mattpilott/phosphor-svelte-test
I'm sure its just a peer dep issue. That repro by the way is a stock install with JS Doc, Prettier and Svelte 5, latest versions. No code changes just added the phosphor dep to the package.json
Hope that helps
@haruaki07 were you able to repro using the above?
I used npm, and I'm unable to install dependencies. It's just the same error message as the one you got earlier https://github.com/haruaki07/phosphor-svelte/issues/23#issuecomment-2137986432. Sure, it's just a peer dependency problem, but how do you even use phosphor-svelte with Svelte 5?
Im not sure, only using a few svelte 5 features atm, for the time being ive moved to a hand-rolled svg sprite. If you get it to work let me know and ill test
Seems like you used Bun as the package manager. I tried to install Bun, and when I ran bun install
, the command appeared to be successful without any dependency conflicts.
npm result:
$ npm i
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: phosphor-svelte-test@0.0.1
npm ERR! Found: svelte@5.0.0-next.155
npm ERR! node_modules/svelte
npm ERR! dev svelte@"^5.0.0-next.144" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer svelte@">=3" from phosphor-svelte@2.0.1
npm ERR! node_modules/phosphor-svelte
npm ERR! dev phosphor-svelte@"^2.0.1" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR!
npm ERR! For a full report see:
npm ERR! /home/<username>/.npm/_logs/2024-06-15T16_28_58_936Z-eresolve-report.txt
npm ERR! A complete log of this run can be found in: /home/<username>/.npm/_logs/2024-06-15T16_28_58_936Z-debug-0.log
bun result:
$ bun install
bun install v1.1.13 (bd6a6051)
+ @sveltejs/adapter-auto@3.2.1
+ @sveltejs/kit@2.5.10
+ @sveltejs/vite-plugin-svelte@3.1.0
+ phosphor-svelte@2.0.1
+ prettier@3.2.5
+ prettier-plugin-svelte@3.2.3
+ svelte@5.0.0-next.144
+ svelte-check@3.8.0
+ typescript@5.4.5
+ vite@5.2.12
110 packages installed [5.26s]
Blocked 1 postinstall. Run `bun pm untrusted` for details.
You could use Bun to install deps for Cloudflare or Vercel if they support it. But that's not gonna fix the conflicting peer deps. So I'm still gonna support Svelte 5.
Im using bun but on cloudflare its not possible to install with bun but you can use it for dev (bun run dev)
Yeah Bun is not supported yet on Clouflare.
Hello,
I'm unable to deploy a svelte kit site on cloudflare when using svelte 5
if i simply add phosphor to the devdeps but dont import it anywhere in my code i get this
Perhaps there is a pee dep update needed?