Evaluation Options Editor API Methods
on()
Registers an event listener for the specified event.
You would want to use this method to run a callback function whenever the specified event fires, for example, to save the options each time they change.
Examples
// Log the options each time they change
editor.on('change', function (options) {
console.log('options have changed', options);
});
Arguments
-
event string
The name of the event to listen for.
Possible values
"change""reset"
-
callback function
The function to run when the event fires.
Return value
None (undefined).