To run Rust code in the browser, start by confirming that your existing app works with WASM WASI and create a simple JavaScript web page. Install the wasm32-unknown-unknown target, wasm-pack, and wasm-bindgen-cli. You'll also need Chrome for Testing and Chromedriver for automating tests. Install these tools into a dedicated subfolder of your home directory. Make your project a library project, add wasm-bindgen dependencies, and test. Learn what types wasm-bindgen supports and change functions to use supported types. Change files to generic BufRead. Adapt tests, skipping those that don't apply. Change to JavaScript-friendly dependencies, if necessary. Run tests. Add wasm-pack to your CI tests.
towardsdatascience.com
towardsdatascience.com
Create attached notes ...
