I have an input field in my ionic form:
<input type="search" placeholder="Search" ng-model="searchKey">
<button class="button button-clear" ng-click="search()">Search</button>
And I wanna add an event that calls the function "search()" when I press enter button of my keyboard.
Is there any suggestion ?
Thank you in advance
You can use this directive ng-enter, like this
<input type="search" placeholder="Search" ng-enter="search()" ng-model="searchKey">
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With