What problem does it solve?
Wiring up user interactions in Makepad 2.0 requires understanding its two-layer event system: Splash inline handlers (on_click, on_render, on_return) and the Rust MatchEvent trait, plus the bridge macros connecting them. This Skill provides the complete patterns, APIs, and working examples so you don't have to reverse-engineer the framework source.
Core Features & Use Cases
- Splash Inline Handlers: Attach on_click, on_render, on_return, and on_startup handlers directly in script_mod! code, including per-item closures in dynamic lists.
- Rust MatchEvent Trait: Handle widget actions, timers, HTTP responses, keyboard input, and lifecycle events with the full handle_actions API for Button, TextInput, CheckBox, DropDown, Slider, and RadioButton.
- Rust-to-Splash Bridges: Use script_eval! to update Splash state and trigger re-renders, and script_apply_eval! to patch widget properties at runtime with #(expr) value interpolation.
- Use Case: Build a todo app where a TextInput's on_return submits a new item, a ScrollYView re-renders the list with per-item delete buttons, and a Rust-side timer polls a remote API whose HTTP response updates the UI via script_eval!.
Quick Start
Ask the AI to build a Makepad 2.0 counter app where clicking a button increments a counter and re-renders the label, using handle_actions and script_eval!.