Commit 25f3938 1 parent 97e5111 commit 25f3938 Copy full SHA for 25f3938
File tree 1 file changed +2
-2
lines changed
md/5_writing_ops/dev_attachments
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -82,15 +82,15 @@ AGFzbQEAAAABCAJgAX8AYAAAAh4BDG15X25hbWVzcGFjZQ1pbXBvcnRlZF9mdW5jAAADAgEBBxEBDWV4
82
82
Now, in the Op code, add this:
83
83
``` javascript
84
84
// create data url from base64 wasm code
85
- const ammoWasm = " data:application/wasm;base64," + attachments .wasm ;
85
+ const simpleWasm = " data:application/wasm;base64," + attachments .wasm ;
86
86
87
87
// define callable functions
88
88
const importObject = {
89
89
" my_namespace" : { " imported_func " : (arg ) => { return console .log (arg); } },
90
90
};
91
91
92
92
// fetch code from dataurl and instantiate wasm
93
- fetch (ammoWasm ).then ((g ) =>
93
+ fetch (simpleWasm ).then ((g ) =>
94
94
{
95
95
WebAssembly .instantiateStreaming (g, importObject).then (
96
96
(obj ) =>
You can’t perform that action at this time.
0 commit comments