0

I have prepared the following plunker http://plnkr.co/edit/XVCtNX29hFfXtvREYtVF?p=preview where I ask you to:

1: digit something in the input field

2: directly click on the button (without touching anything else).

element.on('click',function(){
    scope.clicked=true;
    scope.$apply();
})

Question: why the onclick function doesn't get called? (I know I have used element.on('click',...), I can't use ng-click here, don't ask why.

Do you have any idea on why this happens?

endamaco
  • 153
  • 1
  • 11

1 Answers1

0

it will work if you add 'default' in ng-model-options="{ updateOn: 'default blur'}" ng-model="var" of your input tag

for more information enter link description here

saikumar
  • 1,041
  • 6
  • 10