mirror of
https://github.com/livebook-dev/livebook.git
synced 2025-10-12 22:46:17 +08:00
Modify kino button example to render the button (#1811)
This commit is contained in:
parent
bd41b5b178
commit
b4504e342c
1 changed files with 5 additions and 2 deletions
|
@ -55,8 +55,11 @@ the main way to interact with controls is by listening to their
|
|||
events.
|
||||
|
||||
```elixir
|
||||
Kino.Control.button("Click me!")
|
||||
|> Kino.listen(fn event -> IO.inspect(event) end)
|
||||
button = Kino.Control.button("Click me!")
|
||||
```
|
||||
|
||||
```elixir
|
||||
Kino.listen(button, fn event -> IO.inspect(event) end)
|
||||
```
|
||||
|
||||
<!-- livebook:{"branch_parent_index":0} -->
|
||||
|
|
Loading…
Add table
Reference in a new issue