# Flux > Flux — a write-once UI language for native iOS and Android. Write .flux, hot-reload on device over binary patches, and ship SwiftUI + Jetpack Compose. Source: https://github.com/elcoosp/flux ## Tutorials - [Your first Flux app](https://flux-rs-docs.vercel.app/tutorials/your-first-app.md): Build the Flux CLI, scaffold a project, hot-reload a counter on an iOS or Android host app, and ship a native release — end to end. - [Build the todo app](https://flux-rs-docs.vercel.app/tutorials/todo-app.md): Recreate the real examples/todo app step by step — records, List state, keyed ForEach, controlled text input, routing, and a Storage capability call. ## How-to Guides - [Run and configure the dev server](https://flux-rs-docs.vercel.app/guides/dev-server.md): Configure flux dev — ports, health probe, LAN exposure, and pairing tokens for the hot-reload loop. - [Manage state](https://flux-rs-docs.vercel.app/guides/state-management.md): Patterns over the Flux signal graph — local signals, derived values, shared stores, controlled inputs, and async data through capabilities. - [Navigate between screens](https://flux-rs-docs.vercel.app/guides/navigation.md): Build multi-screen apps with Router, Screen, and RouterNav — the route prop contract, initial routes, and capability-driven navigation. - [Use platform capabilities](https://flux-rs-docs.vercel.app/guides/capabilities.md): Call Camera, Storage, Router, Clipboard, and Location through the versioned capability contract — result cells, permission gating, and error handling. - [Ship a native release](https://flux-rs-docs.vercel.app/guides/build-native.md): Generate SwiftUI and Jetpack Compose sources with flux build ios|android, understand the output layout, and hand the sources to the native toolchains. - [Set up editor tooling](https://flux-rs-docs.vercel.app/guides/editor-tooling.md): Install the VS Code extension and use flux lsp for parse and type diagnostics on .flux sources. - [Format sources and gate CI](https://flux-rs-docs.vercel.app/guides/formatting-and-ci.md): Enforce canonical style with flux fmt --check, catch environment drift with flux doctor --strict, and keep the repo's fmt/clippy gates green. - [Run tests and benchmarks](https://flux-rs-docs.vercel.app/guides/testing-and-benchmarks.md): Exercise the five test layers — nextest, proptest, insta snapshots, criterion budgets, and the dev-vs-release parity harness. - [Migrate from React Native](https://flux-rs-docs.vercel.app/guides/migrate-from-rn.md): An honest map from React Native concepts to Flux primitives — component model, state, effects — and the gaps Flux does not cover yet. - [Migrate from Flutter](https://flux-rs-docs.vercel.app/guides/migrate-from-flutter.md): An honest map from Flutter widgets to Flux primitives — layout, state, async — and the gaps Flux does not cover yet. - [Troubleshoot Flux errors](https://flux-rs-docs.vercel.app/guides/troubleshooting.md): Diagnose Flux errors by class — compile (parse, type, lower), runtime VM faults, and capability denials — with the message shape, root cause, and fix for each. ## Reference - [Language reference](https://flux-rs-docs.vercel.app/reference/language.md): The .flux surface — components, records, signals, closures, view calls, interpolation, operators, and types. - [Standard library reference](https://flux-rs-docs.vercel.app/reference/stdlib.md): Every Flux stdlib component with its real prop contract — layout, text, controls, input, navigation, overlays, motion — plus value types and presets. - [CLI reference](https://flux-rs-docs.vercel.app/reference/cli.md): The flux command-line interface — init, dev, build, lsp, fmt, doc, doctor — with every flag, default, and environment variable. - [flux.toml reference](https://flux-rs-docs.vercel.app/reference/flux-toml.md): The Flux project manifest — project name and entry, dev server ports, and pairing token configuration. - [Wire protocol reference](https://flux-rs-docs.vercel.app/reference/wire-protocol.md): The binary protocol between dev server and host apps — frame header, patch encodings, node and value layouts, prop diffs, closures. - [VM instruction set](https://flux-rs-docs.vercel.app/reference/vm-isa.md): The host VM's register-based ISA — signal ops, monomorphized arithmetic, list ops, closures, fault policy, and the golden vectors that pin it. - [Capabilities reference](https://flux-rs-docs.vercel.app/reference/capabilities.md): The versioned capability contract — stable ids, methods, result cells, permission gating, and how async results return to the signal graph. ## Explanation - [Architecture](https://flux-rs-docs.vercel.app/explanation/architecture.md): How Flux works — the parse → typecheck → lower → diff → patch → VM pipeline, the 16 crates, stable node identity, and the three normative contracts. - [Reactivity and host-authoritative state](https://flux-rs-docs.vercel.app/explanation/reactivity.md): The SolidJS-style signal graph, the host-authoritative state invariant (ADR-0027), and how a tap becomes exactly one update — independent of tree size. - [Dev vs release](https://flux-rs-docs.vercel.app/explanation/dev-vs-release.md): Why Flux has two execution tiers over one IR — interpreted patches in dev, native codegen in release — and how parity is proven. - [The wire, explained](https://flux-rs-docs.vercel.app/explanation/the-wire.md): Why Flux talks binary over WebSocket, how BLAKE3 content addressing keeps patches tiny, and why the dirty set decides what ships. - [Project status](https://flux-rs-docs.vercel.app/explanation/project-status.md): What is verified and runnable in Flux today — the dev hot-reload path, release codegen, tooling — and what is still converging. ## Optional - [How we built a mobile UI compiler with two execution tiers](https://flux-rs-docs.vercel.app/blog/welcome-to-flux.md)