Closed Jacob-o closed 4 years ago
You'll need a ref to the modal selector. Documentation and examples on refs: https://reactnative.dev/docs/direct-manipulation https://medium.com/@payalmaniyar/deep-understanding-of-ref-direct-manipulation-in-react-native-e89726ddb78e
However I would not recommend using getSelectedItem()
unless you have a unique use case and no other option. The onChange
callback prop fires when the user has selected an item. You could store that value in your component's state for use later.
https://github.com/peacechen/react-native-modal-selector#props
How do I use the getSelectedItem() method? Thanks so much!