This is a template for a Rust / WASM project which needs to call requestAnimationFrame()
from within rust code in order to animate HTML canvas.
The template is based on the brilliant example by sifyfy.
git clone [email protected]:dipdowel/rust-wasm-raf-template.git
cd rust-wasm-raf-template
wasm-pack build --target web
While in rust-wasm-raf-template
:
python3 -m http.server
Then open your browser and go to http://localhost:8000
.
Rust, wasm, WebAssembly requestAnimationFrame, requestAnimationFrame(), request_animation_frame, request_animation_frame() canvas, animation, template