File tree 1 file changed +5
-2
lines changed
examples/hello_world/chrome
1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 2
2
3
3
set -ex
4
4
5
- # This is the same as the directory above this.
5
+ # This is the same build.sh, later we are going to use the
6
+ # fetch flag to avoid including the wasm module as a string
7
+ # of base64, instead using the js `fetch` function
8
+ # to request the module from the server.
6
9
cargo +nightly build --target wasm32-unknown-unknown
7
10
cargo +nightly run -p wasm-bindgen-cli --bin wasm-bindgen -- \
8
11
../../../target/wasm32-unknown-unknown/debug/hello_world.wasm --out-dir .
@@ -12,7 +15,7 @@ cargo +nightly run -p wasm-bindgen-cli --bin wasm-bindgen -- \
12
15
cargo +nightly run -p wasm-bindgen-cli --bin wasm2es6js -- \
13
16
--fetch ./hello_world_bg.wasm -o hello_world_bg.js hello_world_bg.wasm
14
17
15
- # And like the directory above this, from here it's the same .
18
+ # Install the npm items as usual .
16
19
npm install
17
20
18
21
# since we kept the same name for the .js module, we need
You can’t perform that action at this time.
0 commit comments