Updated touchable components and added new Expo example with newer React Native version #10
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I had problems in a project, where I updated the React Native version. The fix is mentioned here: sohobloo/react-native-modal-dropdown#251 (comment)
There should not be two touchable components nested.
So I wanted to update the example in this repository. Problem was, that the update of React Native from 0.53.0 made problems. I decided to setup a new example with using Expo (latest SDK 38), which uses React Native 0.62.2.
After that I decided to resolve some open issues. I wanted to make the used touchable component less hard coded. So I created new props to pass components and props for the rendered rows of the dropdown and the main button.
Resolves #7
I encountered problems with using
TouchableNativeFeedback
on Android. I wanted this as default, but theonPress
is not triggered for some weird reason. One can read about problems with that component in the web and also on the official documentation: https://reactnative.dev/docs/touchablenativefeedbackMaybe there is a way to fix that, but I did not find out.
With doing that, it was a small addition to add also new props to be passed for the
Text
, which is rendered when not passingrenderRow
.Resolves #5