Fix web layer

This commit is contained in:
2026-01-07 20:29:15 +01:00
parent bb3d99b011
commit 29ebb83ead
5 changed files with 279 additions and 188 deletions

View File

@@ -1,7 +1,7 @@
let exports;
async function init() {
const resp = await fetch("./chess.wasm");
const resp = await fetch("./chess.wasm?rand=" + crypto.randomUUID());
if (!resp.ok) throw new Error(`fetch wasm failed ${resp.status} ${resp.statusText}`);
const { instance } = await WebAssembly.instantiateStreaming(resp, {});