Architecture of vancoola.dev

A technical review of the portfolio's server-side rendering, browser hydration and the constraints of the chosen stack.

RustLeptosSSRWebAssemblyFly.io

Goal and stack

The site is built with Leptos and Axum. This stack lets me use Rust on the server and in the browser while delivering core content in the initial HTML response.

backendRust · Axum
renderingLeptos SSR
clientWebAssembly hydration
deployDocker · Fly.io

Key decisions

01 / SSR

The server renders the first response, so core content is available before JavaScript and WebAssembly load.

02 / SHARED RUST

Leptos hydrates the interface after the HTML arrives. The server and client share Rust types and some application code.

Request flow

Axum receives the HTTP request and passes it to Leptos. The page is rendered on the server; the browser receives the HTML and then starts WASM hydration.

01Browser
02Axum router
03Leptos SSR
04HTML first, WASM hydration next
Static assets to CDNCDN
HTML responseSSR → WASM

Delivery

RenderingServer-side
ClientWASM hydration
AssetsBrotli compressed

The application is packaged as a Docker image and deployed to Fly.io. Static assets and the WebAssembly bundle are delivered with Brotli compression.

Constraints of the chosen stack

Client bundle sizeFor a mostly static site, WebAssembly ships more code than a minimal JavaScript client.

Build timeCompiling Rust and WebAssembly takes longer than an equivalent Vite or esbuild build.

Ecosystem maturitySome browser integrations require custom implementations because fewer libraries are available than in the JavaScript ecosystem.

This stack is more complex than a portfolio requires. I chose it deliberately because the site also serves as a working Leptos and Axum project.