wasm-bindgen/examples/without-a-bundler-no-modules
2019-03-06 08:01:03 -08:00
..
2019-03-05 08:00:47 -08:00
2019-03-05 08:00:47 -08:00
2019-03-05 08:00:47 -08:00
2019-03-06 08:01:03 -08:00

Without a Bundler Using --no-modules

View documentation for this example online

You can build the example locally with:

$ 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 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.