- From: Brett Zamir <notifications@github.com>
- Date: Sat, 22 Oct 2016 16:10:15 -0700
- To: w3c/IndexedDB <IndexedDB@noreply.github.com>
- Message-ID: <w3c/IndexedDB/issues/49/255559499@github.com>
In the specification, I assume both `window.onerror` and `window.addEventListener('error'...)` handlers will be triggered, and if so, I am wondering whether both should be passed a single error object (as occurs in Chrome when you dispatch an `error` event on `window`) or whether `window.onerror` should be passed the `message`, `source`, `lineno`, `colno`, and error object arguments described at https://developer.mozilla.org/en-US/docs/Web/API/GlobalEventHandlers/onerror and apparently at https://html.spec.whatwg.org/multipage/webappapis.html#handler-onerror . The latter would be harder to faithfully polyfill, however, as one would need to overwrite any user `window.onerror` with a function which detected avoided firing twice (`dispatchEvent` would need to be sent by the polyfill to trigger `addEventListener` events but since that only sends a single error object argument, the polyfill would need to overwrite the user handler to avoid triggering in this instance and instead only trigger when the polyfill directly calls `window.onerror` with multiple arguments). -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/w3c/IndexedDB/issues/49#issuecomment-255559499
Received on Saturday, 22 October 2016 23:10:44 UTC