I would like to properly crash my plugin and prevent any more interactions when an unhandled exception happens, but onerror() is not available. I know wrapping everything in try/catch is an option, but in my case that’s a loooot of work. Is there another automatic way to be notified of errors?
Page 1 / 1
window.onerror
is available. Did you declare it in ui.html
?
I’m not sure what you mean by “declare”. I tried adding to window an event listener for ‘error’, but the event never arrives.
onerror = (event) => console.error(event);
nonExistentVariable;
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.