I have understood your issue. You should have one child inside the
If you are not willing to fill up your file with the
Views then in that case you can also use the React Fragments to achieve your goal. Please refer below code snippets
For even speedy results there is a short syntax also available for the React Fragments. So your above code can also be written as shown below:
You can even face the issue when you have only one child under your
TouchableHighlight. The issue may come up if you have few others commented out but incorrectly. So please make sure that you are commenting out properly.
Hope you have understood the possible reasons behind the error and also the solutions to fix the error.