Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Exceptions in event handlers not catched by $exceptionHandler #7909

Closed
@blambeau

Description

@blambeau

See: https://gist.github.com/blambeau/b865bd2fdacb1f821ac5

myApp.directive('bang', function() {
 return {
   link: function(scope, element, attr) {
     element.on('click', function(){
       throw new Error("Bang!");
     });
   }
 };
});

The Bang! exception above won't be catched by the $exceptionHandler. I'm not sure if it's intentional or not (I understand that it might be hard to catch), but it is at least counterintuitive.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions