Architecture
This section explains Legato as a system, not as an isolated package API.
Use it to understand:
- how responsibility is split between app code, shared contract semantics, Capacitor integration, and native runtime execution,
- why those boundaries exist,
- and which behaviors are stable guarantees versus runtime-dependent outcomes.
Architecture map
Section titled “Architecture map”| Page | Focus |
|---|---|
| System Overview | High-level layer model and responsibility split across consumer app, contract package, Capacitor package, and runtime/native layer. |
| Contract and Runtime Boundaries | Why Legato separates shared semantics from integration mechanics, and which failure modes that boundary prevents. |
| Guarantees and Non-Guarantees | Mental safety model for what is stable by contract and what remains runtime-dependent. |
| Playback Lifecycle | End-to-end command-to-projection lifecycle, including setup, queue, playback events, errors, and resync semantics. |
| Consumer State Model | How to model consumer state with snapshots, events, and capabilities without false inference or UI coupling. |
| Integration Evolution | Maturity path from contract-first alignment to runtime hardening and release-aware upgrade discipline. |
When to read this first
Section titled “When to read this first”Read this architecture section before large integrations if you need to:
- align product and platform teams on stable semantics,
- avoid coupling UI policy to runtime quirks,
- or make explicit risk decisions around capability projection and event handling.