This commit is contained in:
@@ -106,12 +106,13 @@ window.$gz = {
|
|||||||
Vue.config.errorHandler = errorHandler.handleVueError;
|
Vue.config.errorHandler = errorHandler.handleVueError;
|
||||||
window.onerror = errorHandler.handleGeneralError;
|
window.onerror = errorHandler.handleGeneralError;
|
||||||
|
|
||||||
//unhandled rejection handler here
|
// //unhandled rejection handler
|
||||||
window.addEventListener("unhandledrejection", function(event) {
|
//shouldn't need this
|
||||||
// the event object has two special properties:
|
// window.addEventListener("unhandledrejection", function(event) {
|
||||||
alert(event.promise); // [object Promise] - the promise that generated the error
|
// // the event object has two special properties:
|
||||||
alert(event.reason); // Error: Whoops! - the unhandled error object
|
// alert(event.promise); // [object Promise] - the promise that generated the error
|
||||||
});
|
// alert(event.reason); // Error: Whoops! - the unhandled error object
|
||||||
|
// });
|
||||||
|
|
||||||
//warnings, only occur by default in debug mode not production
|
//warnings, only occur by default in debug mode not production
|
||||||
Vue.config.warnHandler = errorHandler.handleVueWarning;
|
Vue.config.warnHandler = errorHandler.handleVueWarning;
|
||||||
|
|||||||
Reference in New Issue
Block a user