12 lines
346 B
JavaScript
12 lines
346 B
JavaScript
|
import wasmInit from "./pkg/gamarjoba.js"
|
||
|
|
||
|
const runWasm = async () => {
|
||
|
const rustWasm = await wasmInit("./pkg/gamarjoba_bg.wasm");
|
||
|
|
||
|
const result = rustWasm.de_iavascriptis(0, 1);
|
||
|
console.log("Should be undefined: ", rustWasm.add_integer_with_constant);
|
||
|
document.body.textContent = `Gamarjoba! result: ${result}`;
|
||
|
};
|
||
|
|
||
|
runWasm();
|