Examples
Every entry below is a file you can run. The catalogs in the repository own the complete list; this page is the short way in.
The counter, running
example/counter.dart is the larger counter: a title bar, a border, arrow
keys, +, -, and explicit pointer handling. It is not the small app from
Your first app; that tutorial shows its own captured
frames.
Core examples
These need only the published noir package. Clone the repository and run them
from packages/noir.
| Source | Command | What it demonstrates |
|---|---|---|
| counter.dart | dart run example/counter.dart | Retained state, keyboard activation, and pointer activation. |
| layout_basics.dart | dart run example/layout_basics.dart | Container, Row, Column, spacing, and flex distribution. |
| focus_form.dart | dart run example/focus_form.dart | Focus cues, validated input, submission, and pointer activation. |
| components_demo.dart | dart run example/components_demo.dart | Every public control under two palettes. |
The core example catalog lists the rest, grouped by concept, controls, complete apps, motion, and advanced reference.
Companion examples
These use the optional noir_signals package. Run
dart pub get at the repository root first, then run the commands from
packages/noir_signals/.
| Source | Command | What it demonstrates |
|---|---|---|
| counter.dart | dart run example/counter.dart | SignalWidget and useState for one local value. |
| task_list.dart | dart run example/task_list.dart | The finished app from the task-list tutorial. |
| file_search.dart | dart run example/file_search.dart | An externally owned model observed with SignalValueBuilder. |
The companion example directory
holds these files and its own index. The tutorial’s first four checkpoints live in
example/tutorials/task_list/.
The final checkpoint is the shipped
example/task_list.dart.
See Installation for the dependency setup these examples assume.