Simple example how to use WASM in node.js projects.
- run
npm install
oryarn
; - check out the code,
index.js
contains the node code that uses wasm files.assembly/index.ts
contains the AssemblyScript code that is compiled to WebAssembly. - Run
npm run asbuild
oryarn run asbuild
to compile to code to webassembly. - Run
node index.js
to see the magical "Hello, Motley" string to appear.