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.

htmlAnchorDirective click event stop bubbling... #1651

@lancon13

Description

@lancon13

Hi, I just upgraded my angular.js from 1.0.2 to 1.0.3, and having an issue with this fix after the upgrade.

Since my app has some elements listen to event delegation from JQuery.

1.0.2
http://plnkr.co/edit/iSem7DYn3b3ERgpD2LTu?p=preview

1.0.3
http://plnkr.co/edit/1SR7IAwrxDmHcE553ylI?p=preview

However, it doesn't work anymore, as the "a" element (htmlAnchorDirective) "click" event now stop bubbling up...

I just looking at the JQuery Doc, it seems "event.preventDefault()" and "return false" should be doing different things.

http://api.jquery.com/bind/

Example: Cancel a default action and prevent it from bubbling up by returning false:
$("form").bind("submit", function() { return false; })

Example: Cancel only the default action by using the .preventDefault() method.
$("form").bind("submit", function(event) { event.preventDefault(); });

Sorry for my bad english...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions