24 lines
437 B
Markdown
24 lines
437 B
Markdown
## Counter
|
|
|
|
The classic counter example explained in the [`README`](../../README.md).
|
|
|
|
The __[`main`]__ file contains all the code of the example.
|
|
|
|
<div align="center">
|
|
<img src="https://iced.rs/examples/counter.gif">
|
|
</div>
|
|
|
|
You can run it with `cargo run`:
|
|
```
|
|
cargo run --package counter
|
|
```
|
|
|
|
The web version can be run with [`trunk`]:
|
|
|
|
```
|
|
cd examples/counter
|
|
trunk serve
|
|
```
|
|
|
|
[`main`]: src/main.rs
|
|
[`trunk`]: https://trunkrs.dev/
|