Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Which error events do no trigger window.onerror?

MDN states the following:

some/many error events do not trigger window.onerror, you have to listen for them specifically

That's great, but which ones do not invoke onerror?

like image 777
Francisc Avatar asked Dec 14 '12 21:12

Francisc


People also ask

What triggers window Onerror?

Introduction. onerror is a DOM event handler. It is started when an error occurs during object loading. While window. onerror is an event handler, there is no error event being fired: instead, when there is an uncaught exception or compile-time error, the window.

What is Onerror event?

The onerror event is triggered if an error occurs while loading an external file (e.g. a document or an image). Tip: When used on audio/video media, related events that occurs when there is some kind of disturbance to the media loading process, are: onabort. onemptied. onstalled.

What are the three information provided by Onerror () method?

The Error object and error. It contains 3 standardized properties: message, fileName, and lineNumber.

What is the use of Onerror?

The onerror attribute fires when an error occurs while loading an external file (e.g. a document or an image).


1 Answers

It looks like quirksmode has a good detail of what errors it will and will not catch: http://www.quirksmode.org/dom/events/error.html

If it helps, any error that you specifically throw will be caught.

like image 88
Shmiddty Avatar answered Sep 23 '22 06:09

Shmiddty