Is it possible to track JS errors that a visitor encounters? Obviously we do our own testing, but from time to time a visitor will be running a certain browser version, or have a particular plugin, at it'll cause a JS error. Likewise sometimes an error in the JS gets to production unnoticed.
It would be extremely useful if we could somehow capture these events, and ajax a script on our server with details of the error so that we could attempt to fix the issue.
UPDATE:
Thanks for the feedback. Typically after posting I managed to find:
Logging Clientside JavaScript Errors on Server
Which had the stuff on window.onerror and also some interesting things about JQuery and a FireFox onerror bug that still hasn't been fixed for years...