I'm working on a complex web application written in Sencha Touch and PhoneGap. The way Sencha Touch applications are written makes it hard to surround every potential failure point with a try/catch, especially with asynchronous AJAX request handlers.
It's also critically important to detect when an unhandled exception occurs because it looks and feels like a native app with PhoneGap (i.e. we can't expect them to refresh the page and try again like in a web app you view in a regular browser).
Can you suggest a recommendation for how to deal with this scenario?