Svelte Local Debugging

Yes, I have to change between these:
import adapter from "@sveltejs/adapter-auto";
import adapter from "@sveltejs/adapter-cloudflare";
import adapter from "@sveltejs/adapter-auto";
import adapter from "@sveltejs/adapter-cloudflare";
13 Replies
Hard@Work
Hard@Work7mo ago
@Sithu Khant I got that part. I meant, when you say it "doesn't work", what do you mean? Does it not start? Does it throw an error? Does it display a broken page?
sithu
sithuOP7mo ago
It is just loading on localhost. I waited for an hour or so. Just loading... I even tried the preview one
Hard@Work
Hard@Work7mo ago
Do you have an example repo I can test with?
sithu
sithuOP7mo ago
It doesn't work either I can't, but there is command I used:
bun create cloudflare@latest <app_name> --framework=svelte --experimental
bun create cloudflare@latest <app_name> --framework=svelte --experimental
Hard@Work
Hard@Work7mo ago
Have you tried with node?
sithu
sithuOP7mo ago
I even tried starting the project via sv create cli instead of cloudflare one I didn't
Hard@Work
Hard@Work7mo ago
Maybe try that, and see if it works?
sithu
sithuOP7mo ago
ah... it worked with npm, I just installed and tried it So, bun isn't supported yet?
Hard@Work
Hard@Work7mo ago
Actually, I think they are actively removing it: https://github.com/cloudflare/cloudflare-docs/pull/19813
GitHub
Remove mentions of Bun by penalosa · Pull Request #19813 · cloudfla...
Summary This PR clarifies Wrangler&#39;s support policy for Bun, and removes mention of Bun for C3. See cloudflare/workers-sdk#8039 for the relevant implementation change, and justification. Ad...
sithu
sithuOP7mo ago
so, Bun won't be supported now and ever?
Hard@Work
Hard@Work7mo ago
That's what it is looking like? It might work at some point, but it wouldn't be officially supported
sithu
sithuOP7mo ago
as my tried, it worked when I run dev with npm although I installed packages with bun
Hard@Work
Hard@Work7mo ago
Yeah, it sounds like whatever bun is doing at runtime doesn't quite mesh with what Wrangler/Vite expects, causing it to break

Did you find this page helpful?