summaryrefslogblamecommitdiffstats
path: root/examples/counter/README.md
blob: 18761bbad42378de2b4e61ad691a6c890211eb7a (plain) (tree)
1
2
3
4
5
6
7
8






                                                                         
                                                  






                                






                                          
                     
                               
## 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/