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@Work4w 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 Khant
Sithu KhantOP4w 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@Work4w ago
Do you have an example repo I can test with?
Sithu Khant
Sithu KhantOP4w 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@Work4w ago
Have you tried with node?
Sithu Khant
Sithu KhantOP4w ago
I even tried starting the project via sv create cli instead of cloudflare one I didn't
Hard@Work
Hard@Work4w ago
Maybe try that, and see if it works?
Sithu Khant
Sithu KhantOP4w ago
ah... it worked with npm, I just installed and tried it So, bun isn't supported yet?
Hard@Work
Hard@Work4w 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 Khant
Sithu KhantOP4w ago
so, Bun won't be supported now and ever?
Hard@Work
Hard@Work4w ago
That's what it is looking like? It might work at some point, but it wouldn't be officially supported
Sithu Khant
Sithu KhantOP4w ago
as my tried, it worked when I run dev with npm although I installed packages with bun
Hard@Work
Hard@Work4w 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?