Asking the Q here before raising a crbug report in case someone points out it's a stupid idea - not strictly a feature of Developer Tools but close enough related that I hope someone might entertain the question...
Chrome recently got a correct window "error" event (window.onerror or window.addEventListener) which made quite a few of us happy
This means we can now write global error handlers, hence my Chrome extension to add a toolbar button to show such errors when Developer Tools are closed
and a project by @OffBeatMammal to add centralised error logging to your apps when they're in use out in the wild
Now what would make it really handy for these typical uses would be to get the stack trace of the error, which I can do within Chrome at any point using Error.captureStackTrace()
but by the time my window error handler is called, the stack of where the error occurred is lost.
Is it possible (or incredibly dumb) to add something like a "stack" property to the ErrorEvent object (as passed to handlers specified with window.addEventListener) - this would basically be the same as the "stack" property on exception objects, and would make global error handling and logging much richer (another option would be to add a property to the ErrorEvent object of the exception object that would be handed to an exception handler if one were in place).
If the answer is "file a crbug" then I'm happy to do so, but if there's a simple reason why NOT to do so, I'd be interested to know
--
Tim