We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wasm-pack new demo
wasm-pack build
const wasm = import('demo');
The text was updated successfully, but these errors were encountered:
试了下 wasm 的 runtime 部分确实有问题,我们之前验过 https://github.com/umijs/mako/blob/master/examples/import-resources/index.tsx#L3 ,需要找时间看下 wasm-pack 产物的差异是什么。
Sorry, something went wrong.
从构建产物对比看,webpack对wasm文件的处理会解析出相应的importsObj。
尝试本地在mako产物中手动补上importsObj,可以正常执行
感觉可以参考的修复:https://github.com/web-infra-dev/rspack/blob/main/crates/rspack_plugin_wasm/src/parser_and_generator.rs#L46
sorrycc
xusd320
Successfully merging a pull request may close this issue.
wasm-pack new demo
创建一个demowasm-pack build
打包const wasm = import('demo');
引入后就报下面这个错, 但是这个 wasm 在 webpack 和 vite 中都是可以使用的.The text was updated successfully, but these errors were encountered: