mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-03-26 06:51:07 +00:00
12 lines
500 B
JavaScript
12 lines
500 B
JavaScript
// Note that unlike the directory above this we don't need to use an
|
|
// asynchronous `import` statement as we're just working with JS here so we can
|
|
// use normal `import { ... }` statements.
|
|
//
|
|
// Unlike before however we have to *also* import the JS file itself containing
|
|
// wasm (generated by wasm2es6js) which has a `booted` promise to let us know
|
|
// when it's ready to go.
|
|
import { greet } from './hello_world';
|
|
import { booted } from './hello_world_wasm';
|
|
|
|
booted.then(() => greet("World!"));
|