The ngClick directive allows you to specify custom behavior when an element is clicked.
<ANY
ng-click="expression">
...
</ANY>
Param | Type | Details |
---|---|---|
ngClick | expression |
Expression to evaluate upon
click. (Event object is available as |
<button ng-click="count = count + 1" ng-init="count=0">
Increment
</button>
<span>
count: {{count}}
</span>