ionic2-select

ionic2: How to display the selected result in the search bar when using ion searchbar with REST API?

送分小仙女□ 提交于 2020-01-07 03:29:06
问题 I want to create a dropdown list with searchbar with the list containing data from a REST API. Initially in the searchbar I created I could just select the item but couldn't display that in the searchbar. I want the selected item to be displayed in the searchbar.How can I display that selected item. I need to display it because I'm building a cascading dropdown list where the input of the first list is served to the second list. I'll be thankful if someone can provide me the code by putting

How to use images inside a select component in Ionic 2

点点圈 提交于 2019-12-05 18:35:16
问题 I am trying to put an image inside a Select component in Ionic 2 : I have put the image source files inside the www/img folder in my Ionic 2 project. However, using a simple img -tag does not display any image using this code: <ion-list> <ion-item> <ion-label>Gaming</ion-label> <ion-select [(ngModel)]="gaming"> <ion-option value="nes"> NES <img src="img/myImage.png"> </ion-option> </ion-select> </ion-item> </ion-list> Does anyone have any idea? 回答1: The ion-select component doesn't allow

How to use images inside a select component in Ionic 2

不问归期 提交于 2019-12-04 03:49:51
I am trying to put an image inside a Select component in Ionic 2 : I have put the image source files inside the www/img folder in my Ionic 2 project. However, using a simple img -tag does not display any image using this code: <ion-list> <ion-item> <ion-label>Gaming</ion-label> <ion-select [(ngModel)]="gaming"> <ion-option value="nes"> NES <img src="img/myImage.png"> </ion-option> </ion-select> </ion-item> </ion-list> Does anyone have any idea? The ion-select component doesn't allow direct customization to itself and anything that you add to ion-select and ion-option which is not as per the