This example contains various crates that render the same app using different strategies. The app package contains the actual app.
This shows how to render web pages at compile time and hydrate them on first page load.
- xtask: Based on the xtask concept, this builds the app, render the initial pages, then serves the app and static pages.
- pre-rendered-client: A shim to run app.
cargo xtask serveThen point your browser at http://127.0.0.1:8000/.
cd packages/client-side-rendered
trunk serve --opencd packages/axum-client
wasm-pack build --target=web
cd ../axum-server
cargo runThen point your browser at http://127.0.0.1:8080/