Some UI libraries (like jQuery UI) relies on DOM events to dispatch updates events. An example would be the jQuery UI sliders, which triggers a "slide" event on its containing
element when the slider changes position and should update the value.
Epoxy previously refused to bind events to non form elements like divs so it was impossible to create bindingHandlers using those events. set() was working correctly but get() was never ever called because the events were never bound due to changable being false. I fixed it so when a user manually passes events, they are bound regardless of if it's a form element or not. Passing events on the DOM for custom widgets is not uncommon so I thought I should share the modification =]
(Note: this is my first pull request ever, please excuse my mistakes if any!)
I ran into this issue yesterday, ended up modifying my local copy of epoxy.js, but would like to see this fix merged and deployed to bower if possible.
Some UI libraries (like jQuery UI) relies on DOM events to dispatch updates events. An example would be the jQuery UI sliders, which triggers a "slide" event on its containing
Epoxy previously refused to bind events to non form elements like divs so it was impossible to create bindingHandlers using those events. set() was working correctly but get() was never ever called because the events were never bound due to changable being false. I fixed it so when a user manually passes events, they are bound regardless of if it's a form element or not. Passing events on the DOM for custom widgets is not uncommon so I thought I should share the modification =]
(Note: this is my first pull request ever, please excuse my mistakes if any!)
Cool, thanks. Out of the country at the moment, I'll try to review in the coming weeks and give the pass/fail/cleanup.
I ran into this issue yesterday, ended up modifying my local copy of epoxy.js, but would like to see this fix merged and deployed to bower if possible.