utils/binding

This module contains functions for creating Widget option bindings.

Source:
Source:

Classes

DebounceBinding

Methods

(static) observe_option()

Source:

This function subscribes to changes to option name. Returns a function which can be called to unsubsribe.

Example
const unsubcribe = observe_useraction(fader, 'value', (value) => {
       console.log('Fader value is %o now.', value);
     });

     setTimeout(unsubscribe, 1000);

(static) observe_useraction()

Source:

This function subscribes to those changes to option name which are initiated by user action. Returns a function which can be called to unsubsribe.

Example
const unsubcribe = observe_useraction(fader, 'value', (value) => {
       console.log('Fader value changed to %o', value);
     });

     setTimeout(unsubscribe, 1000);

This module contains helper functions for using DOM events.

Source:
Source:

Classes

DebounceBinding

Methods

(static) observe_option()

Source:

This function subscribes to changes to option name. Returns a function which can be called to unsubsribe.

Example
const unsubcribe = observe_useraction(fader, 'value', (value) => {
       console.log('Fader value is %o now.', value);
     });

     setTimeout(unsubscribe, 1000);

(static) observe_useraction()

Source:

This function subscribes to those changes to option name which are initiated by user action. Returns a function which can be called to unsubsribe.

Example
const unsubcribe = observe_useraction(fader, 'value', (value) => {
       console.log('Fader value changed to %o', value);
     });

     setTimeout(unsubscribe, 1000);