Initialization Option Items API

customUnload

This function is called when the learner attempts to close the browser window.

You would want to specify this callback so that you can display a custom error notification or dialog in order to warn the learner that they may lose their progress if they don't save, for example.

Examples

var callbacks = {
    customUnload: function () {
        console.log('The callback that is executed when the learner attempts to close the browser window.');
    },
    // ...
};

var itemsApp = window.LearnosityItems.init(
    initializationOptions,
    callbacks
);

Values

Type function

Related articles

Was this article helpful?