3 ms·
Is there documentation on Rust+WebAssembly that is presented more like a conventional book or tutorial? I don't do well with example-driven documentation like
by jake_the_third 8y ago
Is there documentation on Rust+WebAssembly that is presented more like a conventional book or tutorial?
I don't do well with example-driven documentation like these. Resources like the original rust book are excellent though.
- singularity2001 8y agoIs there really that much to learn? You can just target WebAssembly like this: cargo +nightly build --target wasm32-unknown-unknown
- majewsky 8y agoOkay, then how do I run that? How do I interface with the JS/DOM world? (Those are rhetorical questions. I just mean to show that there is, in fact, more to learn.)
- v_lisivka 8y agoTry (after installing of rust and cargo via rustup): # Install support for "wasm" command for cargo: cargo install cargo-wasm # Install wasm target and wasm-gc tool: cargo wasm setup # Create new wasm project: cargo wasm new hello_world and then in hello_world directory: # Build and run wasm project: cargo wasm run
- markdog12 8y agohttps://rustwasm.github.io/book/ https://rustwasm.github.io/book/
- hencoappel 8y agoI'm going to have to be that guy and say, did you try googling it? Here's one guide: https://hackernoon.com/compiling-rust-to-webassembly-guide-411066a69fde https://hackernoon.com/compiling-rust-to-webassembly-guide-4...
- jake_the_third 8y agoI was under the impression that the wasm emscripten target was deprecated in favor of the rust-specific wasm target. Am I wrong?
- steveklabnik 8y agoYou're not. Well, it's not officially deprecated, but it pretty much is, yeah.