I want to log all JS errors in my project during the beta-testing time. Now I do it in the following way:
window.onerror = myErrHandler; function myErrHandler(message, url, line) { $.ajax({ cache: false, type: "post", data: {error:message, url:url, line:line, brouser:navigator.userAgent}, url: "/Home/LogJavaScript/", async: true }); return true; } But this way couldn't help to get any information about call stack. So, information about errors inside jQuery or any other outer scripts couldn't help a lot.
Is there any way to improve such logging?