Angular.js does not provide human-readable error messages by default.
Is there anyway to change the default, cryptic Angular.js exception URL to a more readable error message? As it is, I have to copy the URL, remove the prefix, and paste in the browser to see what the problem is.
For example, transforming the following exception to a more useful error message:
Error: [ng:areq] http://errors.angularjs.org/1.3.0/ng/areq?p0=InterfaceController&p1=not%20a%20function%2C%20got%20undefined y/<@https://ajax.googleapis.com/ajax/libs/angularjs/1.3.0/angular....
To something like:
"Missing required argument to InterfaceController"
I know I can provide my own exception handler:
.factory('$exceptionHandler', function () {
return function errorCatcherHandler(exception, cause) {
console.error(exception);
};
});
Am I approaching this wrong?