ng-dblclick

Handler for dblclick event

Description

The ng-dblclick directive allows you to specify custom behavior when an element is double clicked.

Parameters


ng-dblclick

  • Type: Expression

  • Restrict: A

  • Element: ANY

  • Priority: 0

  • Description: Expression to evaluate upon dblclick event. MouseEvent object is available as $event.

  • Example:

    <div ng-dblclick="$ctrl.greet($event)"></div>
    

Demo

<section ng-app>
  <button
    class="btn btn-dark"
    ng-init="count = 0"
    ng-dblclick="count = count + 1"
  >
    Increment
  </button>
  <span> count: {{count}} </span>
</section>
count: {{count}}