3d-dice / dice-box

3D Game Dice for any JavaScript App
https://fantasticdice.games/
MIT License
127 stars 28 forks source link

wasm streaming compile failed #99

Closed jimshoop closed 4 months ago

jimshoop commented 4 months ago

This error shows in the console but the roller seems to be working fine. Is this a config or compile error on my part or something intrinsic to chrome? I'm using webpack.

wasm streaming compile failed: TypeError: Failed to execute 'compile' on 'WebAssembly': Incorrect response MIME type. Expected 'application/wasm'.

frankieali commented 4 months ago

That looks like a server config issue. If you are serving the ammo.wasm.wasm file then you need to assure the header for Content-Type: is set to application/wasm and not text.

jimshoop commented 4 months ago

Thank you. I noticed it isn't having the issue on the prod server, just my local dev. I'll look into it.