angularionic2directiveangular2-directivesdouble-click

Double Tap/ double click Angular2 & ionic


I am searching on many forums and questions, but nobody seems to ask how to double click ou double tap in Angular/ionic 2 ?

In ionic v1 it was available with on-double-tap (see http://ionicframework.com/docs/api/directive/onDoubleTap/)

Does anyone maybe have a tip or any code to catch double click events on ionic 2 / angular 2?

Maybe through HammerJS?

Thank you very much ! Luis :)


Solution

  • So after 1-2 hours it was obvious, you don't need to catch double click events with Ionic, but with pure JavaScript: dblclick()

    So in Angular 2 it would be: (dblclick)="myFunction()" and that's it!

    Here you will find other events for JavaScript.