Skip to main content
WebAssembly.compile - WASM - Web documentation
function WebAssembly.compile
compile(bytes: BufferSource): Promise<Module>
The `WebAssembly.compile()` function compiles WebAssembly binary code into a `WebAssembly.Module` object. This function is useful if it is necessary to compile a module before it can be instantiated (otherwise, the `WebAssembly.instantiate()` function should be used). [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/compile)

Parameters

Return Type

Promise<Module>