-
Notifications
You must be signed in to change notification settings - Fork 25
Description
It's been great to see the updates here. While the instance phase imports per the wasm-bindgen style remain specified and supported, the ESM Integration now also supports source phase imports of WebAssembly modules of the form:
import source mod from './mod.wasm';
mod instanceof WebAssembly.Module; // truereturning the compiled module which can be instantiated explicitly later on or many times.
It could be nice to allow this to be inlined by this plugin in the same way instance inlining is currently done, but to get a handle to the compiled webassembly module record.
Note that the builtins: ['js-string'] WebAssembly.compile option is also supposed to be passed to compilation now for both instance and source phases to allow string builtin imports.
Happy to engage in further implementation discussion as necessary here or otherwise.