Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ionic onfocusout event equivalent

In Ionic v3 there is an equivalent of onfocus called (ionFocus).

For example to check on focus for an ion button it will be:

<button ion-button (ionFocus)="checkFocus()">Click Me</button>

I was wondering if there was an equivalent for onfocusout.


I tired:

 <button ion-button (ionFocusout)="checkFocus()">Click Me</button>

But that did not work.

Many thanks

like image 326
Yusof Bandar Avatar asked Apr 23 '26 17:04

Yusof Bandar


1 Answers

A more ionic way can be using ionic's ionBlur event which will fire an event whenever the selected element looses focus (i have used it on input and search bar but not on buttons yet)

  (ionBlur)="checkFocus()"
like image 168
Mahesh Jadhav Avatar answered Apr 25 '26 10:04

Mahesh Jadhav



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!