mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-04-24 21:52:13 +00:00
Fixup some documentation
This commit is contained in:
parent
f3f3ebee3a
commit
bdf98f3a11
@ -1,4 +1,4 @@
|
||||
# Without a Bundler
|
||||
# Without a Bundler Using `--no-modules`
|
||||
|
||||
[View documentation for this example online][dox]
|
||||
|
||||
@ -11,3 +11,11 @@ $ wasm-pack build --target no-modules
|
||||
```
|
||||
|
||||
and then opening `index.html` in a browser should run the example!
|
||||
|
||||
Note that this example is in contrast to the [without a bundler][wab] example
|
||||
which performs a similar purpose except it uses `--no-modules` instead of
|
||||
`--browser`. The main difference here is how the shim JS and module are loaded,
|
||||
where this example uses old-school `script` tags while `--browser` uses ES
|
||||
modules.
|
||||
|
||||
[wab]: https://github.com/rustwasm/wasm-bindgen/tree/master/examples/without-a-bundler
|
||||
|
@ -7,7 +7,11 @@
|
||||
You can build the example locally with:
|
||||
|
||||
```
|
||||
$ ./build.sh
|
||||
$ cargo build --target wasm32-unknown-unknown --release
|
||||
$ cargo run -p wasm-bindgen-cli --bin wasm-bindgen -- \
|
||||
../../target/wasm32-unknown-unknown/release/without_a_bundler.wasm \
|
||||
--out-dir pkg \
|
||||
--browser
|
||||
```
|
||||
|
||||
and then opening `index.html` in a browser should run the example!
|
||||
|
Loading…
x
Reference in New Issue
Block a user