jquery - Is it possible to surround all my javascript file with one try catch? -
I wrote a bookmarklet, when a user clicks on it in his browser, it will do some work on the current website and show popup Some results in
Some websites fail to load my booklet because the problem may exist in the current website.
My bookmarklet code is using the jquery library.
Errors in some cases are in Junkie Library, because I do not know about some conflicts or something.
My question is this:
Can I cover up all my bookmarklet codes with a try that will cause an error in all my code and the user Will any other page redirect to 'Error Page'?
Errors will bubble stack towards the original calling function, so if you wrap your entire top-level code Try ... catch so jQuery errors will be caught.
Comments
Post a Comment