Contact [email protected] Explainerhttps://github.com/whatwg/console/issues/50, or perhaps the below summary, should suffice; this is a very small feature.
Specificationhttps://html.spec.whatwg.org/#dom-reporterror Summary This function, available in windows and workers, allows developers to report errors to the console and any global "error" event handlers, in the same way as an uncaught JavaScript exception. It is mainly useful for custom event-dispatching or callback-manipulating libraries. Blink componentBlink>HTML>Script <https://bugs.chromium.org/p/chromium/issues/list?q=component:Blink%3EHTML%3EScript> TAG reviewThis is a minor exposure of browser functionality with a one-line spec. I'm happy to file for review if people think it would be helpful but I don't think there's much architecturally to discuss here. TAG review statusNot applicable Risks Interoperability and Compatibility Low. Mozilla was the one that originally proposed this in the spec PR, and has already shipped. It is likely pretty easy to implement for WebKit as it is just exposing existing functionality to JavaScript. Gecko: Shipped/Shipping. They pass all the web platform tests on wpt.fyi WebKit: No signal ( https://lists.webkit.org/pipermail/webkit-dev/2021-August/031960.html) Web developers: Positive ( https://github.com/whatwg/html/pull/1196#issuecomment-854177687). A number of frameworks and libraries have mentioned that they would use this in the way it was designed, to better report exceptions in their custom callback dispatch code. Activation This feature is somewhat polyfillable using explicit self.dispatchEvent(new ErrorEvent(...)) plus console.error(), but it won't be quite first-class. In the meantime most developers have resorted to setTimeout(() => { throw e; }, 0) which loses stack trace information. Debuggability This feature doesn't need any extra DevTools support. It builds on the existing code that makes exception reporting work. Is this feature fully tested by web-platform-tests <https://chromium.googlesource.com/chromium/src/+/master/docs/testing/web_platform_tests.md> ?Yes <https://wpt.fyi/results/html/webappapis/scripting?label=master&label=experimental&aligned&q=reporterror> Requires code in //chrome?False Tracking bughttps://bugs.chromium.org/p/chromium/issues/detail?id=1233383 Link to entry on the Chrome Platform Status https://chromestatus.com/feature/5634523220934656 This intent message was generated by Chrome Platform Status <https://www.chromestatus.com/>. -- You received this message because you are subscribed to the Google Groups "blink-dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAM0wra-L-Jqk5W2_XLU35t0LhKqnu0igYWJQSE20cqPxwmr3Zg%40mail.gmail.com.
