Author API Initialization
disable_onbeforeunload
Controls whether Author API will ignore the default browser behavior, for showing an unsaved changes warning when navigating away from the page.
You would want to use this to suppress the browser alert if there were any unsaved changes to an Item, Activity, or Widget (Question or Feature) and the author tries to navigate away from the page.
Examples
var initializationOptions = {
"config": {
"global": {
"disable_onbeforeunload": true
}
}
};
Values
Attribute path config.global.disable_onbeforeunload
Default false
Type boolean
Related articles
- The
safeToUnload()
method, which checks if the current Item or Activity being edited has any unsaved changes. - The
setSafeToUnload()
method, which updates the internal status of the specified view to override its status indicating whether it has any unsaved changes.