-
Notifications
You must be signed in to change notification settings - Fork 63
Open
Labels
Description
Hey dear friends!
Do you know about this? https://www.thecssninja.com/javascript/handleevent
I think it would be a nice addition if your eventhandling would accept objects like in vanilla js!
var app = {
state: { title: 'Example' },
handleEvent: function(evt) { ....
render: function() {
return h('button', { onclick: this })
}
...
}
....
No bind is required when you use vanilla htmlButton.addEventListener('click', app)
!
Thanks for your feedback in advance!
sirtimbly