Todo List
Intermediate - useOptimistic Showcase
Instant UI updates with automatic rollback on errors using React 19's useOptimistic hook.
Demo
- Learn composition pattern
- Build with LEGO blocks
LEGO Blocks
- • Provider — State with useOptimistic
- • Input — Add new todo
- • Items — List of todos
⚡ Key Feature:
Add/toggle/delete todos instantly - UI updates before server confirms. Automatic rollback if server operation fails.