You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using DropDown in angular application. I've successfully provided values using ValueList. Then I've created ReactiveForm and attached formControlName to DropDown component. Unfortunately form is updated with selected index instead of selected value.
I've seen few tasks regarding this issue. Nevertheless maybe it would be good to provide users with some configuration to change that behavior? Some libraries provide bindLabel and bindValue options.
It's especially inconvenient when you provide items using async pipe: [items]="items$ | async, because to fetch selected value you have to create another combination of Observables and operators to fetch value for given index.
The text was updated successfully, but these errors were encountered:
Hey @kamilchlebek , thank you for the suggestion. Sadly for the time being I do not plan on adding this. If you look at the ListPicker widget from NativeScript it follows the same concept. If you want the value you can simply handle the selectedIndexChanged and update your value. Or if you need it only for save, you can pull the value by its index before sending the data to your backend.
I'm using DropDown in angular application. I've successfully provided values using
ValueList
. Then I've created ReactiveForm and attachedformControlName
toDropDown
component. Unfortunately form is updated with selected index instead of selected value.I've seen few tasks regarding this issue. Nevertheless maybe it would be good to provide users with some configuration to change that behavior? Some libraries provide
bindLabel
andbindValue
options.It's especially inconvenient when you provide items using async pipe:
[items]="items$ | async
, because to fetch selected value you have to create another combination of Observables and operators to fetch value for given index.The text was updated successfully, but these errors were encountered: