Cookbook
Practical, end-to-end examples that demonstrate Reacton patterns for common application scenarios. Each recipe includes complete, runnable code with line-by-line explanations.
Recipes
| Recipe | Difficulty | Concepts |
|---|---|---|
| Counter App | Beginner | reacton(), computed(), context.watch(), context.update(), ReactonScope |
| Todo App | Intermediate | CRUD operations, filtering, computed counts, ReactonConsumer |
| Authentication | Intermediate | stateMachine(), typed states and events, guard functions, async transitions |
| Form Validation | Intermediate | FormReacton, FieldReacton, validators, async validation, form submission |
| Search with Debounce | Intermediate | Debouncer, reactonQuery, computed, AsyncValue pattern matching |
| Shopping Cart | Intermediate | ReactonModule, PersistenceMiddleware, computed chains, store.optimistic |
| Pagination | Advanced | QueryReacton, paginated fetching, infinite scroll, stale-while-revalidate |
| Offline-First | Advanced | Persistence, optimistic updates, StorageAdapter, Serializer, sync with server |
| Multi-Step Wizard | Advanced | stateMachine, reactonField, store.enableHistory, store.createBranch |
| Real-Time Chat | Advanced | saga, reactonList, typing indicators, connection management |
| Analytics Dashboard | Advanced | selector, lens, reactonQuery with polling, computed aggregations |
What's Next
Start with the Counter App to learn the basics, then progress through the recipes in order.