Skip to content

Document how to use adapter-cloudflare with svelte-kit dev #2966

Closed
@jaymakes11

Description

@jaymakes11

Describe the problem

I can't figure out how to use svelte-kit dev and https://github.com/cloudflare/wrangler2 together while developing locally. This is necessary for sites that utilize Cloudflare's KV store and durable objects.

Is this currently possible?

Describe the proposed solution

If this is currently possible, let's get it documented.

Alternatives considered

I've tried this:

 npx wrangler@beta pages dev .svelte-kit/cloudflare/ --port 3131 -- npx svelte-kit dev --port 3131

The problem with this is that file changes do not update what's being served, nor do they update in the browser. Sveltekit (via Vite) is serving things from memory (as I understand it), but wrangler (beta) is serving the built site that lives in .svelte-kit/cloudflare/.

Importance

i cannot use SvelteKit without it

Additional Information

Note: Earlier I created a discussion on this and I've also reached out in the Discord. There's been no response to either. Hence the reason I'm creating this issue for it. Without this ability, I'm blocked on using Sveltekit.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions