-
Notifications
You must be signed in to change notification settings - Fork 5
Bind Event
Sarsa Parilla edited this page Feb 17, 2022
·
3 revisions
The bind-event directive is the databinding equivalent of inline event handlers. Instead of onclick, you use bind-event-click.
<div bind-repeater-i="#todos.length">
<input type="checkbox"
bind-event-change="#todos[#i].done = thisElem.checked">
<span>{{#todos[#i].text}}</span>
<input type="button" value="Delete"
bind-event-click="#todos.splice(#i,1); doSomethingElse(event)">
</div>