wasm-bindgen
wasm-bindgen
is a library and tool to facilitate
high-level interactions between Wasm modules and JavaScript; it is built with Rust by
The Rust and WebAssembly Working Group.
Yew is built on wasm-bindgen
and specifically uses the following of its crates:
This section will explore some of these crates in a high level in order to make it easier to understand
and use wasm-bindgen
APIs with Yew. For a more in-depth guide into wasm-bindgen
and it's associated
crates then check out The wasm-bindgen
Guide.
For documentation on the above crates check out wasm-bindgen docs.rs
.
Use the wasm-bindgen
doc.rs search to find browser APIs and JavaScript types that have been imported
over using wasm-bindgen
.
wasm-bindgen
This crate provides many of the building blocks for the rest of the crates above. In this section we
are only going to cover two main areas of the wasm-bindgen
crate and that is the macro and some
types / traits you will see pop up again and again.