react-native-dropdown-picker icon indicating copy to clipboard operation
react-native-dropdown-picker copied to clipboard

Add default/any option that reset single mode dropdown

Open asen23 opened this issue 2 years ago • 0 comments

Currently the only way to reset dropdown is by setting the value to null, but i'd like the option to add a "default/any" option that reset the dropdown by user picking it. While it is technically possible by creating a null value like this

{ label: 'Any', value: null }

While it is technically working in javascript, when using typescript the compiler complaint that null is not assignable to ValueType. So i'd like to propose a solution to allow null in ValueType or add a props that insert this default value and its label.

asen23 avatar Sep 07 '23 05:09 asen23