Skip to content

returning false from event no longer cancels prevent default #4782

Closed

Description

@mhevery
  <a href (click)="setupAuthToken(); false">Log in with Github</a>

Should prevent default because last statement is false. This no longer works as of the new compiler.

Activity

  1. modified the milestone: on Oct 27, 2015
  2. modified the milestones: , on Nov 30, 2015
  3. wardbell commented on Dec 8, 2015

    @wardbell
    Contributor

    Might be. Victor seemed to think it was setting preventDefault ... which isn't the same thing as honoring it in our A2 event handling. Interesting that this reads "... no longer ...". I couldn't find an alpha in which it worked.

  4. cexbrayat commented on Dec 9, 2015

    @cexbrayat
    Member

    @wardbell It used to work a long time ago I think, in alpha-2x, but it doesn't anymore, I think since (^click) has become useless to handle bubbling events.

  5. vicb commented on Dec 15, 2015

    @vicb
    Contributor

    This is supposed to work (there is even a test). The problem seems to be with the evaluation of a chained expression (setupAuthToken() && false should work)

  6. added a commit that references this issue on Jan 8, 2016
    e9ce7cf
  7. angular-automatic-lock-bot commented on Sep 7, 2019

    @angular-automatic-lock-bot

    This issue has been automatically locked due to inactivity.
    Please file a new issue if you are encountering a similar or related problem.

    Read more about our automatic conversation locking policy.

    This action has been performed automatically by a bot.

  8. locked and limited conversation to collaborators on Sep 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions