Architecture
VeloxKit is four layers working together. From your code to the screen:
Architecture β click a layer to learn more
Layer 1 β React
Your application is a standard React tree. You write components, hooks, and context exactly as you would for the web. VeloxKit exports its own primitive components (View, Text, Pressable, etc.) instead of DOM elements, but the React model is identical.
// This is just React
function Counter() {
const [n, setN] = useState(0)
return (
<View>
<Text>{n}</Text>
<Pressable onPress={() => setN(n + 1)}>
<Text>+</Text>
</Pressable>
</View>
)
}Layer 2 β Runtime
VeloxKit runs a purpose-built V8 runtime (not Node.js, not Deno). The runtime:
- Starts from a V8 snapshot β a pre-warmed heap image that eliminates parse/compile time
- Hosts a custom React reconciler that produces a scene graph instead of a DOM
- Bridges JavaScript calls to native Rust bindings via a typed FFI
The reconciler translates React's virtual DOM into VeloxKit's native element tree β a data structure the GPU renderer can consume directly.
Layer 3 β Renderer
The positioned element tree is rasterized by one of three backends, selected automatically based on the hardware (renderMode: 'auto'):
| Backend | Default on | ~RAM | Description |
|---|---|---|---|
| TinySkia | iGPU, no GPU, CI | ~97 MB | Pure CPU rasterizer β no GPU allocation |
| FemtoVG | Intel Arc dGPU | ~103 MB | OpenGL triangle tessellation |
| Vello | NVIDIA / AMD dGPU | ~285 MB | wgpu GPU compute β best visual quality |
Vello runs on DirectX 12 (Windows), Metal (macOS), and Vulkan (Linux). TinySkia runs on any machine with no GPU requirement.
Every component β a View, a Text, a Canvas β becomes renderer draw calls. There is no intermediate HTML, no CSS layout engine, no DOM. VeloxKit implements its own flexbox layout engine in Rust (Taffy).
Layer 4 β Shell
The shell handles OS integration: native windows, system tray, file dialogs, clipboard, notifications. It wraps the GPU surface and exposes the veloxWindow API to your React code.
Data flow
Your React code
β reconciler
Element tree (Rust)
β layout (Taffy)
Positioned boxes
β renderer (TinySkia / FemtoVG / Vello β auto-selected)
Screen pixelsThe entire path from a setState call to a repainted frame takes 1β3ms on modern hardware.
What VeloxKit is NOT
- Not a WebView wrapper β there is no HTML or CSS rendered
- Not a transpiler β your React code runs as-is in V8
- Not Electron β there is no Chromium, no Node.js, no
ipcRenderer - Not a Rust framework β JS-only projects require no Rust at all. Native extension projects (
veloxkit-cli create --native) let you write Rust to expose custom bindings, but this is opt-in.