AdelRedaa97 / react-native-select-dropdown

react-native-select-dropdown is a highly customized dropdown | select | picker | menu for react native that works for andriod and iOS platforms.
MIT License
320 stars 137 forks source link

Required select dropdown field #96

Closed sbozzella closed 1 year ago

sbozzella commented 1 year ago

Is possibile to make select dropdown value required? Could be added to a form in a class component?

I have different select dorpdown in the same screen and i want that user has to select each one before an event (click of button).

Thank you.

AdelRedaa97 commented 1 year ago

Save the returned value from the select dropdown in your component state and make the initial value to be null and in your validator function check if the state has a value or still null "user didn't choose an option"