mirror of
https://github.com/pyscript/pyscript.git
synced 2025-12-19 18:27:29 -05:00
fix issue with example code not showing created button
This commit is contained in:
@@ -216,8 +216,9 @@ Card(p("This is a cool card!"), image="https://pyscript.net/assets/images/pyscri
|
||||
"elements": {
|
||||
"button": {
|
||||
"instance": btn,
|
||||
"code": """button("Click me!")
|
||||
"code": """btn = button("Click me!")
|
||||
when('click', btn)(lambda: window.alert("Clicked!"))
|
||||
parentdiv.append(btn)
|
||||
""",
|
||||
},
|
||||
"div": {
|
||||
|
||||
Reference in New Issue
Block a user