Fine-grained Control over the DOM Source in Cycle.js

André Staltz
InstructorAndré Staltz

Share this video with your friends

Send Tweet

What if we wanted to change the behavior of our app reset the timer every time the mouse hovers over it? Currently we only support clicks, and they are hard coded in the DOM Driver. This lesson will introduce DOMSource.selectEvents(), a way of making the DOM Source rich and allowing the main() function to determine which read effects it needs.