Declarative UI for Luca Code
Describe a screen, write its logic in Luca Code, and let state drive what renders. You never command components — the UI derives from your state.
curl -fsSL https://raw.githubusercontent.com/LucaEcosystem/luca-ui/main/install.sh | sh
App:
id = "app"
state:
greeting = "Hello, Luca!"
Text:
id = "greeting"
text = greeting
One declarative layer, one logic seam, one implemented backend.
State-driven descriptions
UI output derives from application state and declared properties. No component references, no show(), hide(), or setter calls.
One-way Luca Code seam
Luca Code owns general-purpose logic; results re-enter UI state only via set/flush. Luca Code never depends on Luca UI.
Events route to names
Events route to handler names, never to components — executing the paired .lucc logic is Luca Code's job.
Luca errors, frozen wording
Every failure is a source-located Error at line:column: message — pinned by a tested diagnostics catalog.
What it renders.
Rendered by the real luca-ui static SVG backend itself — source on the left, the snapshot it writes on the right.
App:
id = "app"
layout:
direction = "column"
gap = 12
padding = 16
width = 560
height = 300
align = "stretch"
style:
background = "#0b1222"
color = "#f4f1e8"
border = "#33415c"
radius = 12
font_size = 16
Main:
layout:
direction = "row"
gap = 12
align = "stretch"
State:
layout:
direction = "column"
gap = 8
padding = 12
width = 258
style:
background = "#1d2d44"
border = "#33415c"
radius = 8
Text:
text = "visits = 2"
style:
color = "#4dd2ff"
font_size = 14
-- title bar, screen panel and log follow
State on the left, the screen it derives on the right — deterministic and self-contained: 6 rect and 16 text primitives in one SVG document, no interaction, animation, fonts or accessibility tree. The command above ran for real to produce this file.
Running in about a minute.
The prebuilt binary needs no Rust toolchain; it verifies against published SHA256SUMS.
luca-ui --version # luca-ui 1.0.3 Beta
What works, what doesn't.
1.0 Beta — the toolchain is real and tested, with labeled assumptions
93 Rust tests, a frozen diagnostics catalog, and static SVG rendering are in. Some syntax is a labeled assumption (◐) that may change before 1.0 stable — anything that may change is marked in the docs, and the compatibility page states plainly what is locked and what is open.
Documentation.
Core concepts, components, backends, diagnostics, compatibility, styling, examples, the CLI and the VS Code extension.