Advanced Features
Reacton's core is intentionally small -- reacton(), computed(), watch(), set(). But when your application grows, Reacton scales with you through a set of opt-in advanced features that cover enterprise-grade requirements.
Feature Overview
| Feature | Description | Use Case |
|---|---|---|
| Middleware | Intercept reacton lifecycle events (init, read, write, dispose) | Logging, validation, analytics, persistence |
| Persistence | Auto-persist reacton values to storage | User preferences, auth tokens, cached data |
| History | Undo/redo with full action audit log | Form editing, drawing apps, time-travel debugging |
| State Branching | Git-like branching for state | Form preview, A/B testing, speculative updates |
| State Machines | Typed state/event transitions with guards | Auth flows, wizards, complex workflows |
| Modules | Group related reactons with lifecycle management | Feature isolation, team boundaries, lazy loading |
| Observable Collections | Reactive lists and maps with granular change events | Todo lists, user directories, inventories |
| Multi-Isolate | Share state across Dart isolates | Heavy computation, background processing |
Progressive Complexity
You do not need to use any of these features to build a great app with Reacton. They are additive -- adopt them one at a time as your requirements demand.
Level 1: reacton() + computed() + watch() ← 80% of apps
Level 2: effects, selectors, async reactons ← derived state, API calls
Level 3: middleware, persistence, history, branching ← enterprise featuresWhat's Next
- Middleware -- Intercept and transform reacton operations
- Persistence -- Auto-save state to disk
- History -- Add undo/redo to any reacton