I was just taking another look at vrac. It seems like there's a lot of similarities with https://blog.phronemophobic.com/reusable-ui-components.html. Is there an example for how effects might work?
(defc todo-item-comp [todo-item]
{:id :my-app/todo-item}
[:.title {:class {:done? (:todo-item/done? todo-item)}}
(:todo-item/title todo-item)])
How would you emit a :toggle-todo for todo-item when the user clicks on the todo item?@smith.adriane It would look like:
(defc todo-item-comp [todo-item]
{:id :my-app/todo-item}
[:div.title {:class [(when (:todo-item/done? todo-item)
:done?)]
:on-click [:toggle-todo todo-item]}
[:todo-item/title todo-item]]])