Menci / vite-plugin-wasm

Add WebAssembly ESM integration (aka. Webpack's `asyncWebAssembly`) to Vite and support `wasm-pack` generated modules.
MIT License
281 stars 16 forks source link

Plugin fails to load a WASM file create with GOLANG #51

Closed ethastings closed 1 month ago

ethastings commented 7 months ago

When attempting to load a WASM that was written in Golang and compiled using GOARCH=wasm GOOS=js go build -o mian.wasm the resulting vite app does not load and has this error in the web browser console: Uncaught SyntaxError: missing '}' after module specifier list [main.wasm:6:17]

Menci commented 7 months ago

Could you please attach the WASM file?