Skip to content

Commit 4b44e92

Browse files
fix: Set loader: { '.wasm': 'copy' } in esbuild config in adapter-cloudflare-workers
Copies WASM files in Cloudflare instead of trying to load them. Related to sveltejs#9909
1 parent 2e6da94 commit 4b44e92

File tree

1 file changed

+5
-1
lines changed
  • packages/adapter-cloudflare-workers

1 file changed

+5
-1
lines changed

packages/adapter-cloudflare-workers/index.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,11 @@ export default function ({ config = 'wrangler.toml' } = {}) {
6363
outfile: main,
6464
bundle: true,
6565
external: ['__STATIC_CONTENT_MANIFEST'],
66-
format: 'esm'
66+
format: 'esm',
67+
bundle: true,
68+
loader: {
69+
'.wasm': 'copy'
70+
}
6771
});
6872

6973
builder.log.minor('Copying assets...');

0 commit comments

Comments
 (0)